Python3 fix for unauthorized_handler unit test.