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

latest requests package switched chardet to charset_normalizer #296

Closed
wangsha opened this issue Aug 2, 2021 · 2 comments · Fixed by #301
Closed

latest requests package switched chardet to charset_normalizer #296

wangsha opened this issue Aug 2, 2021 · 2 comments · Fixed by #301

Comments

@wangsha
Copy link

wangsha commented Aug 2, 2021

psf/requests#5797
This PR created breaking changes for python 3.

  File "/home/runner/.local/share/virtualenvs/-6eY8Floq/lib/python3.7/site-packages/requirementslib/models/lockfile.py", line 16, in <module>
    from .requirements import Requirement
  File "/home/runner/.local/share/virtualenvs/-6eY8Floq/lib/python3.7/site-packages/requirementslib/models/requirements.py", line 53, in <module>
    from .setup_info import (
  File "/home/runner/.local/share/virtualenvs/-6eY8Floq/lib/python3.7/site-packages/requirementslib/models/setup_info.py", line 16, in <module>
    import chardet
ModuleNotFoundError: No module named 'chardet'
@jrottenberg
Copy link

So requirementslib uses chardet :

https://github.com/sarugaku/requirementslib/blob/master/src/requirementslib/models/setup_info.py#L16

but used to get it through request, until the PR @wangsha linked. Can we make chardet a dependency ?

https://github.com/sarugaku/requirementslib/blob/master/setup.cfg#L60

@HitLuca
Copy link

HitLuca commented Aug 13, 2021

What I'm wondering is how this issue hasn't been spotted since is a clear import error

yukihiko-shinoda added a commit to yukihiko-shinoda/asyncffmpeg that referenced this issue Aug 16, 2021
mammo0 added a commit to mammo0/py-simple-factory-pattern that referenced this issue Aug 30, 2021
mammo0 added a commit to mammo0/py-simple-classproperty that referenced this issue Aug 30, 2021
mammo0 added a commit to mammo0/py-simple-plugin-loader that referenced this issue Aug 30, 2021
mammo0 added a commit to mammo0/py-simple-singleton that referenced this issue Aug 30, 2021
bryant-finney pushed a commit to Madoshakalaka/pipenv-setup that referenced this issue Nov 6, 2021
* chore: Adds `chardet` as prod dependency

Version 4.0.0 has been tested, so no breaking changes from 3.x.x

fixes side-effect of `requirementslib` not specifying `chardet` as dep
sarugaku/requirementslib#296 is still open

User will not need to install `chardet` manually to use this package
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 a pull request may close this issue.

3 participants