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

DM-46401: fix support for multiple instruments (etc) in where expressions #1083

Merged
merged 3 commits into from
Sep 23, 2024

Conversation

TallJimbo
Copy link
Member

@TallJimbo TallJimbo commented Sep 19, 2024

Checklist

  • ran Jenkins
  • added a release note for user-visible changes to doc/changes
  • (if changing dimensions.yaml) make a copy of dimensions.yaml in configs/old_dimensions

Copy link

codecov bot commented Sep 19, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 2 lines in your changes missing coverage. Please review.

Project coverage is 89.69%. Comparing base (568f80b) to head (622876d).
Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
...lsst/daf/butler/direct_query_driver/_query_plan.py 85.71% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1083   +/-   ##
=======================================
  Coverage   89.69%   89.69%           
=======================================
  Files         360      360           
  Lines       47061    47077   +16     
  Branches     9661     9664    +3     
=======================================
+ Hits        42213    42228   +15     
  Misses       3480     3480           
- Partials     1368     1369    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

We want to flag a constraint like 'visit=X' with no instrument as
needing an instrument constraint, or (if one is available) use the
instrument from the butler's default data ID.  But we were also
flagging constraints like 'instrument=X', and while that on its own
provides the needed constraint, 'instrument=X OR instrument=Y' does
not, and hence always failed.
Instead of requiring a new-query-system WHERE constraint to lock down
the (e.g.) instrument to a single value in order to allow a dependent
value (e.g. detector) to appear, we now just check that instrument
appears somewhere in the expression, since that'd catch the most likely
mistake of leaving the instrument out entirely (or assuming incorrectly
that a default would be available).
Copy link
Contributor

@dhirving dhirving left a comment

Choose a reason for hiding this comment

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

Looks good to me

@TallJimbo TallJimbo merged commit 8c62bcf into main Sep 23, 2024
18 checks passed
@TallJimbo TallJimbo deleted the tickets/DM-46401 branch September 23, 2024 14:06
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.

2 participants