kennethreitz/requests — pull request #1575 by jparise (2013-09-03 23:21:51+00:00)
Title: Improved content encoding detection.

`get_encodings_from_content()` can now detect HTML in-document content
encoding declarations in the following formats:

- HTML5
- HTML4
- XHTML 1.x served with text/html MIME type
- XHTML 1.x served as XML

Ref: http://www.w3.org/International/questions/qa-html-encoding-declarations