You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
1.0 KiB

4 years ago
  1. python-webencodings
  2. ===================
  3. This is a Python implementation of the `WHATWG Encoding standard
  4. <http://encoding.spec.whatwg.org/>`_.
  5. * Latest documentation: http://packages.python.org/webencodings/
  6. * Source code and issue tracker:
  7. https://github.com/gsnedders/python-webencodings
  8. * PyPI releases: http://pypi.python.org/pypi/webencodings
  9. * License: BSD
  10. * Python 2.6+ and 3.3+
  11. In order to be compatible with legacy web content
  12. when interpreting something like ``Content-Type: text/html; charset=latin1``,
  13. tools need to use a particular set of aliases for encoding labels
  14. as well as some overriding rules.
  15. For example, ``US-ASCII`` and ``iso-8859-1`` on the web are actually
  16. aliases for ``windows-1252``, and an UTF-8 or UTF-16 BOM takes precedence
  17. over any other encoding declaration.
  18. The Encoding standard defines all such details so that implementations do
  19. not have to reverse-engineer each other.
  20. This module has encoding labels and BOM detection,
  21. but the actual implementation for encoders and decoders is Python’s.