moved wsgi wrappers outside of __main__