Implement Client ID / Client Secrect urlencoding with test
Better imports

Narrowed down the scope of the imports, after checking out compat.py as
suggested, testsuite is happy.
Revert unintentional newline removal
Move unquote_plus import to compat.py
Merge remote-tracking branch 'origin/fix-urlencode-clientid-secret'