-
Notifications
You must be signed in to change notification settings - Fork 126
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
Error when using queries with the BP5 engine #3707
Comments
One significant difference between reader-side BP3 and BP5 is that BP5 doesn't load all variable metadata on Open(). In particular, the default Open mode (Mode::Read, which requires Begin/EndStep), it doesn't load that information until the first BeginStep(). BP3 used to load all the variable information immediately, and then you could either do BeginStep, or start accessing steps randomly using SetStepSelection(). That was flexible, but performance-wise it made Open hugely expensive at scale and was particularly wasteful if you were just going to access data step-by-step. BP5 changed that and only does metadata load immediately if you use Open(Mode::ReadRandomAccess). We had to change a lot of tests and add a mention in the release notes because this does break old code, but it was deemed necessary. For Query in general it may mean a more significant redesign, but you can make the test work by just adding the mode specifier. (I'm surprised this didn't come up earlier. We tried to kill the explicit SetEngine("bp3") in everything in the "testing" directory, but I wasn't aware that there were any regression tests in the "performance" directory. But there were discussions of this change in the dev meetings too of course.) |
That makes sense. I'll change the testing to use BP5 with I would also like queries to be able to see the min/max of sub-blocks. I was using |
Update: I still see the error when I open the file with |
Interesting... I'll take a look in a bit. |
There are two places where a file gets opened with
Unfortunately as written, the tests won't work in BP5 either mode because BeginStep is explicitly forbidden if you use ReadRandomAccess mode and the metadata isn't loaded on open in Read mode... So we really have to bite the bullet and rethink this a bit for it to work with the newer BP5 variable semantic. |
I think this is resolved. @guj let me know if not, otherwise I'll close this issue |
yes, please close it. |
If I try to use a query on a BP file created with BP5 I get errors about variables not existing.
To reproduce the error, use the BP5 engine in the testing code:
When running it, I get this error:
The text was updated successfully, but these errors were encountered: