You can't import various modules as the same name
, e.g.
from moduleX import somevar as X
from moduleY import othervar as X
Results in X == othervar
.
But anyway you can't have multiple applications running in the same instance of Python. That's because
The application object is simply a callable object that accepts two arguments [PEP 333].
Now, a simple WSGI application is something like:
def simple_app(environ, start_response):
"""Simplest possible application object"""
status = '200 OK'
response_headers = [('Content-type', 'text/plain')]
start_response(status, response_headers)
return ['Hello world!\n']
As you can see, there is no place here to make multiple applications working at the same time, due to the fact that every request is passed to ONE particular application callback.