-
-
Notifications
You must be signed in to change notification settings - Fork 428
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
Improve repo configuration based on scientific python suggestions #6554
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6554 +/- ##
==========================================
- Coverage 92.41% 92.39% -0.02%
==========================================
Files 615 614 -1
Lines 54892 54908 +16
==========================================
+ Hits 50729 50733 +4
- Misses 4163 4175 +12 ☔ View full report in Codecov by Sentry. |
@@ -103,6 +103,7 @@ commands = | |||
!cov: python \ | |||
-m pytest {env:PYTEST_PATH:} --color=yes --basetemp={envtmpdir} \ | |||
--ignore tools --maxfail=5 --json-report \ | |||
linux: --pystack-threshold=60 --pystack-args="--native-all" \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why this change? I guess it's because of the added -ra
option maybe?
@@ -151,10 +148,12 @@ xarray = "xr" | |||
[tool.pytest.ini_options] | |||
# These follow standard library warnings filters syntax. See more here: | |||
# https://docs.python.org/3/library/warnings.html#describing-warning-filters | |||
addopts = "--maxfail=5 --durations=10 -rXxs" | |||
addopts = ["--maxfail=5", "--durations=10", "-ra", "--strict-markers", "--strict-config"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@brisvag Asked changes comes from using --strict-config
here.
It causes pytest to fail if some option is not recognized. It makes harder to configure optional plugins, but save from making typos in configuration options.
Here issue in pytest-pystack bloomberg/pytest-pystack#9
I'll mark my review as stale since you're still doing lots of testing and I wanna avoid accidental merge. Ping me when you think things are ok! |
@brisvag I found that the problem was caused by logging level (I do not know why). But now it is ready for review, and debug of logging will be another PR. |
# References and relevant issues # Description In #6554 I have added the graphviz installation step to produce a leaked widgets graph. Unfortunately, brew is reporting some errors on installing python 3.12 during installation of graphviz. This PR makes graphviz installation steep optional. So in post cases we will still have leaked widgets graph, but do not crash the test suite.
Description
The Scientific python has tool named repo-review with set of rules that they think are good for projects.
Not all apply to napari, but some of them looks usefull. To see the check on napari repo one may use this link
https://learn.scientific-python.org/development/guides/repo-review/?repo=napari%2Fnapari&branch=main
This PR contains non mypy improvements, as mypy ones requires improvements in code.
It depends on #6557
This PR also enables automatically dump graph when QtViewer is leaked during tests. Then such graph in pdf is uploaded as job artifact.