-
|
If so, is this worth documenting somewhere? It threw me a bit for a loop. Thanks for your work on this tool. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Sort of -- the answer is that that the "plain" and SARIF formats are 1-based because they're either "human" formats (in the case of plain) or they have a specification that requires them to be 1-based (SARIF and GitHub annotations). By contrast, the JSON format is (mostly) a direct dump of zizmor's internal representation, which is entirely 0-based. So what you're seeing here is mostly an artifact of me leaking an internal detail of zizmor 🙂 I think this would be unfortunately not easy to fix with the current version of the JSON output, although I'd something I'd like to fix with the "v2" format once I have a better sense of how that should be structured.
Yes! I'd happily take a PR adding a note or warning to the JSON format docs here: |
Beta Was this translation helpful? Give feedback.
Sort of -- the answer is that that the "plain" and SARIF formats are 1-based because they're either "human" formats (in the case of plain) or they have a specification that requires them to be 1-based (SARIF and GitHub annotations).
By contrast, the JSON format is (mostly) a direct dump of zizmor's internal representation, which is entirely 0-based. So what you're seeing here is mostly an artifact of me leaking an internal detail of zizmor 🙂
I think this would be unfortunately not easy to fix with the current version of the JSON output, although I'd something I'd like to fix with the "v2" format once I have a better sense of how that should be structured.