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

Remove filterwarnings configuration #1252

Merged
merged 1 commit into from
Dec 4, 2020
Merged

Remove filterwarnings configuration #1252

merged 1 commit into from
Dec 4, 2020

Conversation

jdufresne
Copy link
Member

@jdufresne jdufresne commented Nov 28, 2020

Contributor checklist
  • Provided the tests for the changes.
  • Gave a clear one-line description in the PR (that the maintainers can add to CHANGELOG.md on release).
  • Assign the PR to an existing or new milestone for the target version (following Semantic Versioning).

@jdufresne jdufresne added trivial tests Testing and related things labels Nov 28, 2020
@jdufresne jdufresne added this to the 5.5.0 milestone Nov 28, 2020
@jdufresne jdufresne added the maintenance Related to maintenance processes label Nov 29, 2020
@atugushev
Copy link
Member

No longer appear during tests so these filters can safely be removed.

I've tried it locally and got these warnings:

================================== warnings summary ==================================
.venv/src/pip/src/pip/_vendor/packaging/version.py:127: 72 warnings
tests/test_cli_compile.py: 5049 warnings
tests/test_cli_sync.py: 936 warnings
tests/test_repository_local.py: 108 warnings
tests/test_repository_pypi.py: 756 warnings
tests/test_resolver.py: 20 warnings
tests/test_top_level_editable.py: 81 warnings
  /Users/albert/Projects/pip-tools/.venv/src/pip/src/pip/_vendor/packaging/version.py:127: DeprecationWarning: Creating a LegacyVersion has been deprecated and will be removed in the next major release
    warnings.warn(

tests/test_resolver.py: 22 warnings
  /Users/albert/Projects/pip-tools/.venv/src/pip/src/pip/_vendor/packaging/specifiers.py:283: DeprecationWarning: Creating a LegacyVersion has been deprecated and will be removed in the next major release
    warnings.warn(

-- Docs: https://docs.pytest.org/en/stable/warnings.html

Since pip-tools has no control over what uses pip internally those warnings were disabled intentionally to avoid distraction. However, pip-tools uses vendored packages too:

$ git grep pip._vendor | wc -l
      13

This makes me think that we should not filter those warnings to avoid missing a valuable warning 🤔

@jdufresne
Copy link
Member Author

Okay, I can reproduce the warnings locally. Not sure what I was looking at before.

This makes me think that we should not filter those warnings to avoid missing a valuable warning thinking

IMO, this is the right thing to do. We don't want to ignore upstream warnings if they could point towards required action. Shall we go ahead?

@jdufresne jdufresne changed the title Remove outdated filterwarnings configuration Remove filterwarnings configuration Dec 3, 2020
@codecov
Copy link

codecov bot commented Dec 3, 2020

Codecov Report

Merging #1252 (b2af778) into master (749f782) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1252   +/-   ##
=======================================
  Coverage   99.59%   99.59%           
=======================================
  Files          36       36           
  Lines        2947     2947           
  Branches      333      333           
=======================================
  Hits         2935     2935           
  Misses          6        6           
  Partials        6        6           

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 749f782...b2af778. Read the comment docs.

Copy link
Member

@atugushev atugushev left a comment

Choose a reason for hiding this comment

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

IMO, this is the right thing to do. We don't want to ignore upstream warnings if they could point towards required action. Shall we go ahead?

Yeah, let's merge it then. Thanks! 👍

@jdufresne jdufresne merged commit 83dffeb into jazzband:master Dec 4, 2020
@jdufresne jdufresne deleted the filter-warnings branch December 4, 2020 09:33
@jdufresne
Copy link
Member Author

The warning listed above looks like the upstream issue: pypa/setuptools#2466

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Related to maintenance processes tests Testing and related things
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants