influxdata / influxdata/kapacitor
Invalid number of arguments for integral, expected 1, got 2
- Dominant language
- Go
- Stars
- 2.4k
- Forks
- 479
- Avg merge
- 4d 16h
- Merged PRs (30d)
- 4
Description
When trying to create TICKscript by Chronograf
```
var data = batch
|query('''
SELECT integral("value") AS "value"
FROM "pulsar"."temporary"."raw"
''')
.period(1m)
.cron('* * * * *')
.groupBy(time(1m), 'source')
.fill('null')
|log()
|influxDBOut()
.database('test')
.retentionPolicy('temporary')
.measurement('signal')
.precision('s')
```
error is returned:
`failed to parse InfluxQL query: invalid number of arguments for integral, expected 1, got 2`
But according to the [documentation](https://docs.influxdata.com/influxdb/v1.7/query_language/functions/#integral), the function can take two arguments.
Contributor guide
Research direction
Start by reproducing the Chronograf-generated TICKscript and its InfluxQL query, then inspect how Kapacitor parses the integral function arguments. Compare the parser behavior with the linked InfluxDB documentation. Done means the documented two-argument usage is handled consistently, with the reported invalid-arguments error resolved or clarified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100