You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This error message speaks of an expression/integer, but it actually takes a compile-time constant expression that evaluates to a positive integer, which is more limiting.
$ zq 'yield {x:1} | head x'
zq: expression value must be an integer value: error("missing") at line 1, column 20:
yield {x:1} | head x
~
This topic was surfaced in a recent community Slack thread. Similar error messages show up with head, tail, and top.
$ zq -version
Version: v1.18.0
$ zq 'yield {x:1} | head x'
zq: expression value must be an integer value: error("missing") at line 1, column 20:
yield {x:1} | head x
~
$ zq 'yield {x:1} | tail x'
zq: expression value must be an integer value: error("missing") at line 1, column 20:
yield {x:1} | tail x
~
$ zq 'yield {x:1} | top x x'
zq: limit argument must be an integer at line 1, column 19:
yield {x:1} | top x x
~
In recent PRs #5276 and #5296 we're making sure user-facing docs emphasize that each of these parameters should be a "compile-time constant expression that evaluates to a positive integer". However, since some users may not have read the docs, we could stand to improve the error message.
The text was updated successfully, but these errors were encountered:
tl;dr
This error message speaks of an expression/integer, but it actually takes a compile-time constant expression that evaluates to a positive integer, which is more limiting.
Details
Repro is with Zed commit c1da204.
This topic was surfaced in a recent community Slack thread. Similar error messages show up with
head
,tail
, andtop
.In recent PRs #5276 and #5296 we're making sure user-facing docs emphasize that each of these parameters should be a "compile-time constant expression that evaluates to a positive integer". However, since some users may not have read the docs, we could stand to improve the error message.
The text was updated successfully, but these errors were encountered: