python-poetry / poetry

Python packaging and dependency management made easy
https://python-poetry.org
MIT License
31.17k stars 2.25k forks source link

DeprecationWarning due to old requests_toolbelt version pinned #2939

Closed onecrayon closed 4 years ago

onecrayon commented 4 years ago

Issue

When running tests in my project with pytest I was getting the following error:

DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated

I tracked this down to an issue in requests-toolbelt which was fixed years ago. Poetry for some reason is pinning requests-toolbelt at 0.8.0, and so far as I can tell the fix was introduced in 0.9.x. What are the historical reasons for this being pinned? I would be happy to update its pin and submit a PR, but wanted to know what the background was (couldn't find it in the closed issues, or I searched the wrong terms).

finswimmer commented 4 years ago

Hello @onecrayon,

can you please provide your pyproject.toml so that one can reproduce your issue?

fin swimmer

onecrayon commented 4 years ago

@finswimmer I don't really see what the pyproject.toml will give you, since as I already stated the deprecation warning is being issued due to Poetry itself pinning requests-toolbelt at 0.8.0, but if it will make you happy:

https://gist.github.com/onecrayon/0eabe7bb0b882678b442fc4eea75108d

I'd really appreciate an answer to my primary question:

What are the historical reasons for this being pinned? I would be happy to update its pin and submit a PR, but wanted to know what the background was (couldn't find it in the closed issues, or I searched the wrong terms).

finswimmer commented 4 years ago

Hello @onecrayon, I see now :)

I guess when the dependency was add, the 0.8.x was the current available version. The version constraint is set to ^0.8.0, which is equivalent to to >=0.8.0,<0.9.0. Which makes sense, because for versions <1.0 any minor change can introduce a breaking change.

@sdispater can we upgrade this dependency?

fin swimmer

github-actions[bot] commented 6 months ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.