- Notifications
You must be signed in to change notification settings - Fork989
chore: switch to charset normalizer#4060
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:main
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Uh oh!
There was an error while loading.Please reload this page.
k�nnen |
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.
For curiosity reasons, what's the story with these being added
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.
In the unit tests on the old file,charset_normalizer
misdiagnosed it (chardet
had previously gotten it right). So I added some stuff by re-encodingumlauts-utf8.md
to give it more content on which to make an inference.
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.
As far as the content ofumlauts-utf8.md
, I think it was suggested by a user in a github issue.
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.
Surprisingly simple!
Co-authored-by: Ahmet Melek <39141206+ahmetmeleq@users.noreply.github.com>
Removes
chardet
as a dependency, standardizing oncharset-normalizer
.This involved:
chardet
tocharset-normalizer
in our base dependency filechardet
was usedcharset-normalizer
misdiagnosed the encoding of a file used as a test fixture. My guess is that the ~10 characters in the file were not enough forcharset-normalizer
to do a proper inference, so I re-encoded another slightly longer file that's also used for encoding testing, and it got that one.