This PR is to apply after #7.
It is made of 3 commits:
Copy dictionary keys when modified inside a loop as Python 3.x no longer copies the dictionary when getting the keys, and therefore the loop fails with an exception because the dictionary is changed inside the loop.
Properly handle memoryview objects, encoding and decoding them when appropriate. Use UTF-8 when translating from or to strings, as well as when logging articles.
This PR is to apply after #7. It is made of 3 commits: