Conversation
Modeled after @ericpre PR in exspy: https://github.com/hyperspy/exspy/pull/156/files Co-Authored-By: Eric Prestat <11851990+ericpre@users.noreply.github.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #772 +/- ##
=======================================
Coverage ? 95.90%
=======================================
Files ? 93
Lines ? 7286
Branches ? 986
=======================================
Hits ? 6988
Misses ? 214
Partials ? 84 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Done and ready for review. |
|
Thanks for opening this PR. But to ease reviewing, can you revert the copyright commits? Let's only format the files we change, leaving unchanged files. |
|
@argerlt, if it's fine with you, the I can bring this across the finish line as described in #767 (comment). |
for more information, see https://pre-commit.ci
|
@hakonanes sure that works. I did a few things just now which you can include or remove:
My logic being, functionality testing should be done for every PR on every OS and relevant dependency combination, but things like downloads only need be tested once a week, and if we are doing those tests anyway, it's not much more work to track the total coverage then, as opposed to the coverage-minus-ignored-tests being reported after every single push to a PR branch. That said, I'm fine being hands-off on this PR now. There are multiple ways to handle this issue, feel free to "take this accross the finish line" however you would like from here. |
|
Thanks again. But, we should report coverage on every commit to a PR. Many people don't check coverage locally, only on PR commits. I didn't know GitHub provides four CPUs in their test runners! I thought they only provided two... Perhaps it changed recently? Anyways, glad you made that change! |
Changing it back just to avoid too many quick-and-dirty patch changes, but do we actually need this? The coverage is still reported in the tests by this line: but because there is no coverall check like in orix: Having uncovered lines (I think?) still doesn't trigger a test failure. I suppose this is something to discuss in a separate issue though, not a patch. |
047b4b9 to
7179896
Compare
|
Woof, okay, sorry about that. I made a whitespace typo in the The weekly tests work now. Apologies for the long string of force-pushes. I believe this is ready to go. |
Description of the change
Reduces the number of calls to zenodo so the unit tests once again pass. should solve #767
This is done in two ways:
The test
test_data.py:test_dataset_availabilitynow pauses for 30 seconds after every failed ping, and will attempt up to 3 consecutive pings per file before failing.This gets around the new Zenodo requests limit discussed in the blog post below:https://blog.zenodo.org/2025/11/25/2025-11-14-search-api-updates/
There is a new pytest flag
test_downloads. Tests with this flag will be ran only once in a dedicated VM, as opposed to 7 times (one per OS/python version combo). Since these tests are also time consuming, this has the side benefit of speeding up the overall testing time slightly.Progress of the PR
For reviewers
__init__.py.section in
CHANGELOG.rst.kikuchipy/__init__.pyand.zenodo.json.