john-parton / chardetng-py Goto Github PK
View Code? Open in Web Editor NEWSimple python binding for rust chardetng library
License: MIT License
Simple python binding for rust chardetng library
License: MIT License
LookupError: unknown encoding: windows-874
In a previous version, I just passed the entire buffer to encoding_rs and had it handle decoding entirely in rust, but that was a little confusing.
Need more robust aliases
Here's the current supported architecture/os matrix.
Linux | Windows 8 and Newer | FreeBSD 10 and Newer | macOS Snow Leopard (10.6) | |
---|---|---|---|---|
x86 | ✅ | ❌ | ❌ | ⬜ |
x86_64 | ✅ | ✅ | ❌ | ✅ |
ppc64le | ✅ | ⬜ | ❌ | ⬜ |
AArch64 | ✅ | ❌ | ❌ | ✅ |
ARMv7 | ✅ | ⬜ | ❌ | ⬜ |
s390x | ✅ | ⬜ | ❌ | ⬜ |
https://pythondev.readthedocs.io/platforms.html
In compat.detect
, the confidence is always 0.99:
chardetng-py/python/chardetng_py/compat.py
Lines 16 to 18 in f90b454
It’s possible I’m misunderstanding things, but it seems like you could use guess_assess()
instead of guess()
to at least determine high vs. low confidence. From the chardetng docs:
Same as
guess()
, but also returns a Boolean indicating whether the guessed encoding had a higher score than at least one other candidate. If this method returnsfalse
, the guessed encoding is likely to be wrong.
On a related note, it would be nice if shortcuts.detect()
returned the boolean from guess_assess
, too (or had another method that did so), since the aliases buried in the shortcuts module seem pretty important, and possibly prone to change. Otherwise a user has to know about them if they want to safely use guess_assess
instead. (Or the aliases could be documented and moved to a more accessible place.)
Currently, can be difficult for new users to find docs. Add clearer links to documentation
Originally suggested here: #109 (comment)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.