Fix imports that broke under some conditions
Replace Response.content with Response.text for Python 3 compatibility

Fix #5
Fix #6