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-36108: move Ellipsis typing workaround from daf_butler #137

Merged
merged 2 commits into from Sep 6, 2022

Conversation

TallJimbo
Copy link
Member

@TallJimbo TallJimbo commented Sep 5, 2022

Checklist

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

My in-editor mypy has long complained about this, even though the
command-line one doesn't seem bothered by it.  It's easy enough to fix.
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.

Looks okay but can you have a test that imports the code so that we know it will import?

python/lsst/utils/sets/__init__.py Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Sep 5, 2022

Codecov Report

Merging #137 (c28f55c) into main (c0c52bc) will decrease coverage by 0.12%.
The diff coverage is 77.27%.

@@            Coverage Diff             @@
##             main     #137      +/-   ##
==========================================
- Coverage   92.24%   92.12%   -0.13%     
==========================================
  Files          42       44       +2     
  Lines        2709     2729      +20     
==========================================
+ Hits         2499     2514      +15     
- Misses        210      215       +5     
Impacted Files Coverage Δ
python/lsst/utils/ellipsis.py 60.00% <60.00%> (ø)
tests/test_ellipsis.py 90.00% <90.00%> (ø)
python/lsst/utils/packages.py 88.43% <100.00%> (ø)

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


from typing import TYPE_CHECKING

if TYPE_CHECKING:
Copy link
Member Author

Choose a reason for hiding this comment

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

It's expected for codecov to complain about this block, because by design it's only ever seen by MyPy and other type-checkers: we don't actually want it to run in tests.

@TallJimbo TallJimbo merged commit e7fd1f4 into main Sep 6, 2022
@TallJimbo TallJimbo deleted the tickets/DM-36108 branch September 6, 2022 14:31
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