8000 Remove contextlib.nullcontext compat shim in favor of pip's version by jdufresne · Pull Request #1283 · jazzband/pip-tools · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Remove contextlib.nullcontext compat shim in favor of pip's version #1283

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

Merged
merged 1 commit into from
Jan 1, 2021
Merged

Remove contextlib.nullcontext compat shim in favor of pip's version #1283

merged 1 commit into from
Jan 1, 2021

Conversation

jdufresne
Copy link
Member

This removes the need to maintain yet another compatibility shim that is
already handled by pip. pip has a vendored copy of contextlib2, which
contains the same copy of the function.

At some point in the future, pip-tools can use the stdlib version
instead.

Contributor checklist
  • Provided the tests for the changes. (n/a)
  • 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 this to the 6.0.0 milestone Dec 31, 2020
@codecov
Copy link
codecov bot commented Dec 31, 2020

Codecov Report

Merging #1283 (d72c280) into master (61cb487) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1283   +/-   ##
=======================================
  Coverage   99.65%   99.65%           
=======================================
  Files          35       35           
  Lines        2905     2906    +1     
  Branches      324      324           
=======================================
+ Hits         2895     2896    +1     
  Misses          5        5           
  Partials        5        5           
Impacted Files Coverage Δ
piptools/repositories/pypi.py 97.26% <100.00%> (+0.01%) ⬆️

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 61cb487...d72c280. Read the comment docs.

This removes the need to maintain yet another compatibility shim that is
already handled by pip. pip has a vendored copy of contextlib2, which
contains the same copy of the function.

At some point in the future, pip-tools can use the stdlib version
instead.
@jdufresne jdufresne merged commit 0036708 into jazzband:master Jan 1, 2021
@jdufresne jdufresne deleted the null-context branch January 1, 2021 17:27
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.

2 participants
0