Closed zacharyburnett closed 2 years ago
Merging #163 (7c007f9) into master (272061b) will not change coverage. The diff coverage is
50.00%
.
@@ Coverage Diff @@
## master #163 +/- ##
=======================================
Coverage 84.87% 84.87%
=======================================
Files 13 13
Lines 1633 1633
=======================================
Hits 1386 1386
Misses 247 247
Impacted Files | Coverage Δ | |
---|---|---|
stsynphot/commissioning/utils.py | 29.82% <50.00%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 272061b...7c007f9. Read the comment docs.
Good catch but I have a question as stated in the code comment.
Also, why is your test suite importing from the commissioning
folder?
Also, why is your test suite importing from the
commissioning
folder?
It looks like this is happening during pytest
test discovery, as I called pytest --pyargs stsynphot
to test the package within the environment. So, when it collects tests from commissioning/tests
, it runs through import of commissioning/__init__.py
-> commissioning/utils.py
-> this error
To exclude commissioning folder, please see the tox.ini
defined in this repo. Your test suite needs to pick this up:
Description
Direct import from
collections
is deprecated in Python 3.10. This causes the environment testing in https://github.com/spacetelescope/spacetelescope-env-distribution to fail:https://github.com/spacetelescope/spacetelescope-env-distribution/runs/7429139594?check_suite_focus=true#step:11:31
The solution is to import from
collections.abc
instead.