Skip to content
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

Fix reading relations to unpersisted objects #486

Merged
merged 6 commits into from
Sep 22, 2023

Conversation

tmadlener
Copy link
Collaborator

@tmadlener tmadlener commented Sep 15, 2023

BEGINRELEASENOTES

  • Make sure to initialize ObjectIDs to untracked to properly track whether they have been added to a Frame or not
  • Change CollectionIDTable interfaces of name and collectionID to return optional to signal whether a collection (ID) is known to the table. This is a breaking change if you use the CollectionIDTable!
    • Avoids having to do the lookup twice to check existence and a subsequent retrieval
  • Fix bug of overly shared CollectionIDTable in ROOTNTupleReader that was uncovered by the CollectionIDTable switch to optional returns.
  • Switch tests from EventStore to Frame based I/O.
  • Fix bug in Frame based I/O that lead to crashes when trying to resolve relations to unpersisted objects.

ENDRELEASENOTES

@tmadlener tmadlener changed the title [WIP] Fix reading relations to unpersisted objects Fix reading relations to unpersisted objects Sep 18, 2023
@tmadlener tmadlener requested review from hegner and jmcarcell and removed request for hegner September 18, 2023 14:02
@tmadlener
Copy link
Collaborator Author

This seems to be a breaking change at least for the legacy I/O algorithms in k4FWCore. Should we aim for a smoother migration or do we just merge the two PRs "in sync"?

Copy link
Collaborator

@hegner hegner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Looks good to. In particular adding the default initialization

@hegner hegner merged commit af3e98e into AIDASoft:master Sep 22, 2023
17 checks passed
Ananya2003Gupta pushed a commit to Ananya2003Gupta/podio that referenced this pull request Sep 26, 2023
* Switch test case from EventStore to Frame based I/O

* Default initialize ObjectIDs to untracked

* Add check for existence before getting collections

* Properly lock the collection ID table

* Make CollectionIDTable return optional for some queries

* Make sure that each category gets its own id table
@tmadlener tmadlener deleted the frame-based-tests branch November 8, 2023 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Frame based I/O crashes when reading objects with related object that were not persisted
2 participants