influxdata / influxdata/influx-cli
White space in CSV annotations cause Invalid Argument Errors
- Dominant language
- Go
- Stars
- 75
- Forks
- 22
- PR merge metrics
- No merged PRs in 30d
Description
More of a nit than a critical bug. Take an example annotation such as:
```
#datatype measurement, double, double, double
measurement,x,y,z
demo,-0.514,0.070,1.672
```
executing `influx write ... ` will return "unsupported data type ' double'"
This can be remediated by simply removing the whitespace from the annotation row:
`#datatype measurement,double,double,double`
I wonder if there's a quick fix in [normalizeNumberString](https://github.com/influxdata/influx-cli/blob/35279515e98a1844338a6f8d03e10c0fd864a599/pkg/csv2lp/data_conversion.go#L95)
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in pkg/csv2lp/data_conversion.go at normalizeNumberString, which the issue identifies as a possible entry point for handling whitespace in CSV annotations. Reproduce the sample with `influx write ...`, then verify that spaces after commas in the #datatype row are accepted and no longer produce an unsupported data type error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 58/100