Open necessarily-equal opened 3 months ago
Thanks @necessarily-equal for this feedback. You are correct that this should not fail with such an error. We will address this.
Thanks for the report, turns out it was not just a bad error message but also a bug underneath. The fix for it is now commited in our non-public repo and will be merged sometime in the future
In cases where one tries to access the index of a sequence, no nice error message is printed but the frontend “panics” and prints a generic error message instead:
It could print a nice error message such as “tried to access index 0 of a sequence, in JSONiq indexes start at 1.” This may affect arrays also, I didn't test that case.