lxml does not support strings with an encoding declaration. They must be bytes objects if there is an encoding declaration. Previously, this error was grouped in with others. This separates two possible ValueErrors that lxml may raise so that it's clearer.
The tests are failing because a str and a bytes are equivalent at Python 2. This means that lxml has more functionality when using Python 2 than Python 3, so the error does not occur.
286 should be merged first
lxml does not support strings with an encoding declaration. They must be bytes objects if there is an encoding declaration. Previously, this error was grouped in with others. This separates two possible ValueErrors that lxml may raise so that it's clearer.
This issue was highlighted in #285