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-39857: Major cleanup #102

Merged
merged 23 commits into from Jul 1, 2023
Merged

DM-39857: Major cleanup #102

merged 23 commits into from Jul 1, 2023

Conversation

timj
Copy link
Member

@timj timj commented Jun 30, 2023

  • Add ruff configuration (including docstyle)
  • Clean up docs to run in nitpicky mode.
  • Remove --flake8 test option.
  • Modernized type annotations.
  • Fixed all warnings from tests.

Checklist

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

@codecov
Copy link

codecov bot commented Jun 30, 2023

Codecov Report

Patch coverage: 89.04% and project coverage change: +0.08 🎉

Comparison is base (36d8d83) 85.24% compared to head (f80511f) 85.33%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #102      +/-   ##
==========================================
+ Coverage   85.24%   85.33%   +0.08%     
==========================================
  Files          46       46              
  Lines        3627     3621       -6     
==========================================
- Hits         3092     3090       -2     
+ Misses        535      531       -4     
Impacted Files Coverage Δ
...ython/lsst/pex/config/configurableActions/tests.py 92.10% <ø> (ø)
python/lsst/pex/config/convert.py 35.00% <ø> (ø)
python/lsst/pex/config/registry.py 84.61% <ø> (ø)
python/lsst/pex/config/wrap.py 11.30% <0.00%> (ø)
tests/test__file__.py 93.75% <ø> (ø)
tests/test_dictField.py 95.19% <ø> (ø)
tests/test_history.py 94.44% <ø> (ø)
tests/test_listField.py 93.20% <ø> (ø)
tests/test_ticket1911.py 95.00% <ø> (ø)
tests/test_ticket1914.py 93.75% <ø> (ø)
... and 31 more

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

@timj timj requested a review from TallJimbo July 1, 2023 00:14
@timj
Copy link
Member Author

timj commented Jul 1, 2023

@TallJimbo most of the commits do not need reviewing. I've tried to make it clear which ones are fixes for sphinx, and which are automated. I did do some commits to fix warnings that involved actual code changes.

Copy link
Member

@TallJimbo TallJimbo left a comment

Choose a reason for hiding this comment

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

One commit here has a lot of namespace-qualification in docs that I would not have thought was necessary.

I didn't look at the "modernize type annotations" or "modernize string formatting" commits at all as I guessed those were fully automated.

Otherwise looks good!

python/lsst/pex/config/config.py Show resolved Hide resolved
python/lsst/pex/config/configField.py Show resolved Hide resolved
timj added 15 commits July 1, 2023 10:07
This means that the file will be cleaned up automatically
and the coverage code will no longer complain about coverage
in python files it wasn't meant to be finding.
Pytest looks for tests in classes named TestX. Importing TestConfig
therefore triggers a warning. Now reference it from the original
package.
Modified find_module to be compatible with find_spec. Fixes this warning:

tests/test_Config.py::ConfigTest::testBadImports
tests/test_Config.py::ConfigTest::testImports
  <frozen importlib._bootstrap>:914: ImportWarning: RecordingImporter.find_spec() not found; falling back to find_module()
@timj timj merged commit 82a771d into main Jul 1, 2023
10 checks passed
@timj timj deleted the tickets/DM-39857 branch July 1, 2023 17:43
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