Error Unmarshalling Response
- Dominant language
- Go
- Stars
- 3
- Forks
- 4
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
I'd just like to raise an issue I've discovered. At least occasionally, when making a query for a report I've seen an unmarshalling issue where the struct requires a float32 but a value of "NaN" string is returned. Understandably this type mismatch causes an issue. Since the json and the struct definition are not compatible the entire content of the response is lost.
https://github.com/adobe/aa-client-go/blob/23c70ca292246808be81056ae7e75db4fb5a6973/analytics/reports-types.go#L177
Contributor guide
Research direction
Start with analytics/reports-types.go at the linked line and inspect how report responses are unmarshalled into the float32 field. Reproduce the report query with a response containing the string "NaN" and trace where decoding fails. Done means the response can be handled without losing its entire contents, with the behavior covered by an appropriate test if the repository has one.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- api
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100