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

Switch to or logic when multiple merge ids in restriction #1126

Merged
merged 2 commits into from
Sep 20, 2024

Conversation

samuelbray32
Copy link
Collaborator

@samuelbray32 samuelbray32 commented Sep 20, 2024

Description

  • Merge.extract_merge_id() was introduced in Apply restrictions on parent tables in fetch_nwb #1086 to help allow restriction by Merge table or parent table in Merge.fetch_nwb()
  • The logic of this function created a And restriction when multiple merge ids were present in the restriction
    • This would always lead to an empty table when applied since an entry can't match 2 different merge_id values
  • This PR changes the restriction returned by Merge.extract_merge_id() to or logic to allow proper function.

Checklist:

  • N This PR should be accompanied by a release: (yes/no/unsure)
  • NA If release, I have updated the CITATION.cff
  • N This PR makes edits to table definitions: (yes/no)
  • NA If table edits, I have included an alter snippet for release notes.
  • NA If this PR makes changes to position, I ran the relevant tests locally.
  • I have updated the CHANGELOG.md with PR number and description.
  • NA I have added/edited docs/notebooks to reflect the changes

@samuelbray32 samuelbray32 marked this pull request as ready for review September 20, 2024 18:21
Copy link
Member

@CBroz1 CBroz1 left a comment

Choose a reason for hiding this comment

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

This will need tests in the future, but I can work add them in my next pass if you don't have bandwidth right now

@edeno edeno merged commit a9f6a7f into master Sep 20, 2024
7 checks passed
@edeno edeno deleted the extract_merge_id_logic branch September 20, 2024 22:32
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.

3 participants