Fix bug in reset token
Update setup.py and requirements for pytest and webtest
Linting fixes