Fix SECRET_KEY encode in Python 2

fix #106