-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sql: panic: runtime error: index out of range #39540
Comments
This panic is very weird. I've tried a few things to pin-point the cause to no success. Some observations:
|
So the root cause panic here is actually that we're trying to
I believe a This all begs the question - how did we manage to get ourselves into a situation where we have an invalid In particular, I see one big difference between how non-vectorized uses
And here's the vectorized equivalent:
Note that in non-vectorized we always allocate a fresh decimal. In vectorized we hoped to not have to do that - and as a result we pass a "garbage" value (whatever used to be in I thought that this was valid because of the godoc of
Is this actually invalid? Are you not allowed to pass a non-zero value as the first argument of @mjibson, I believe you might have an idea of the expected contract here? |
As a datapoint, if I change the vectorized implementation to zero it, there's no panic.
|
Ah, I think the problem here is actually our implementation of copying decimals from one vector to another. We perform a shallow copy, which is something that is explicitly banned by |
Good find. Also, you should be using the same apd context ( |
The text was updated successfully, but these errors were encountered: