I do not see this line in the code but I assume you have it toplevel
in a module. That is not allowed. The module is executed only once
when first imported.
If you import it outside the wsgi application the request has not been
parsed yet. Even if it were request would always be the first request,
I use 'current' in a function in a model like this:
=
def send_email_message_web2py(
reply_to,
reply_to_email_addr,
sender_organization,
massimo's point about caching of modules probably applies here. i have
seen this sort of sometimes behavior before and in my cases was able to
link it back to first request on a GAE instance vs later request on an
instance. i had this problem with the custom importer (which i patched and
is
it seems too complicated issue. I tried and made a task handler
on an URL and it works well.
Got a message that it could be up to 100KB?!?
we are at the edge of my knowledge here, but the things that might be
important to you from gae_handler.py:
path = os.path.dirname(os.path.abspath(__file__))
sys.path = [path]+[p for p in sys.path if not p==path]
from gluon.settings import global_settings
global_settings.web2py_runtime_gae
good - if I go through this - you will get deferred too. ;) I am very close.
Actually the error I get is here:
request = current.request
AttributeError: 'local' object has no attribute 'request'
So there is 'current' but there is not a 'request'
can you point it at web2py/gae_handler.py or base your deferred handler off
of that?
8 matches
Mail list logo