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-37938: additional spatial constraint query fixes and testing #787

Merged
merged 5 commits into from Feb 11, 2023

Conversation

TallJimbo
Copy link
Member

@TallJimbo TallJimbo commented Feb 10, 2023

See also lsst/daf_relation#6

Checklist

  • ran Jenkins
  • added a release note for user-visible changes to doc/changes

@TallJimbo
Copy link
Member Author

The build_and_test failure is just because it needs the daf_relation branch; I'll just re-run after that lands instead of adding a temporary pin this time.

Copy link
Member

@timj timj left a comment

Choose a reason for hiding this comment

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

Thanks for the extensive tests.

This provides a new approach to testing registry queries that won't
require as much work setting up appropriate test data and inspecting it
to independently determine expected query results, and I'm looking
forward to adding more tests here on future tickets; so far this just
focuses on the spatial constraint queries that we apparently had
particularly poor test coverage previously, leading to lots of breakage
on DM-31725.

Some of these tests are expected to fail right now, but will be fixed
shortly.
There was a bit of a mess here previously - two nearly-identical blocks
for deciding which columns would be included in the query, and one of
them going unused; I think that's relic of a poorly-resolved rebase
conflict somewhere in the long development of DM-31725.
There's currently no high-level way to populate these arguments to our
lower-level query classes; the only way one can currently do temporal
constraints is to write them out in the 'where' argument, and that
doesn't use any of this.

I've made this a separate commit because I think we may want to revert
it after we've got a public interface (possibly on Butler rather than
Registry) that's designed to support all of the things the daf_relation
query system could now do.  But for now it's just dead weight.
@codecov
Copy link

codecov bot commented Feb 11, 2023

Codecov Report

Base: 85.49% // Head: 85.51% // Increases project coverage by +0.02% 🎉

Coverage data is based on head (80c95a8) compared to base (460accc).
Patch coverage: 90.21% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #787      +/-   ##
==========================================
+ Coverage   85.49%   85.51%   +0.02%     
==========================================
  Files         265      266       +1     
  Lines       35047    35075      +28     
  Branches     6004     7358    +1354     
==========================================
+ Hits        29964    29996      +32     
+ Misses       3768     3766       -2     
+ Partials     1315     1313       -2     
Impacted Files Coverage Δ
...ython/lsst/daf/butler/registry/queries/_structs.py 86.14% <88.46%> (+0.66%) ⬆️
tests/test_query_relations.py 88.67% <88.67%> (ø)
...ython/lsst/daf/butler/registry/queries/_builder.py 92.42% <100.00%> (+9.09%) ⬆️
python/lsst/daf/butler/registry/tests/_registry.py 98.16% <100.00%> (ø)
...hon/lsst/daf/butler/core/_column_categorization.py 88.57% <0.00%> (-2.86%) ⬇️
...lsst/daf/butler/registry/queries/_query_context.py 83.33% <0.00%> (-2.57%) ⬇️
...thon/lsst/daf/butler/registry/dimensions/static.py 89.54% <0.00%> (ø)
...ython/lsst/daf/butler/registry/dimensions/table.py 93.92% <0.00%> (+1.10%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@TallJimbo TallJimbo merged commit c645d68 into main Feb 11, 2023
@TallJimbo TallJimbo deleted the tickets/DM-37938 branch February 11, 2023 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.

None yet

2 participants