Hi Randy,
Thanks for your comment.
Le 2016-10-11 à 19:44, Randy Syring a écrit :
For what it's worth, I also think you might misunderstand how WSGI
works. I believe the environment object is supposed to exist in a
request context. I'm assuming you only need one user per request, so
simply filling in the value of REMOTE_USER seems to me like it should
work. However, I haven't looked at your code or thought long about
the problem, it's just an off-handed observation based on your
description below.
I believe the OAuth2 middleware and client is functioning correctly and
is setting the REMOTE_USER value as expected. But I guess the problem is
because I recreate a new WebOb request object before returning a WSGI
response. Also, I need to update the WSGI environment for each request
in order to preserve the value of REMOTE_USER. However, i don't know if
it's logical to recreate a WSGI request every time. Perhaps the solution
would be to use a global request object...
Regards,
Etienne
--
Etienne Robillard
tkad...@yandex.com
http://www.isotopesoftware.ca/
_______________________________________________
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe:
https://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com