I have a server with one web2py instance (fronted by nginx/uwsgi), two apps, and a routes.py that says app1 is default.
I recently (that is, last night) added a new function to app2, protected (as usual) with @auth.requires_membship('innercircle'). In addition, I had to create a new user 'goodguy' and add it to 'innercircle'. I tested from a browser instance that also had routine use of app1. I spent a lot of time that was supposed to be for testing the form in trying to get logged in correctly. I eventually tried .../user/profile, and found I was not getting logged in as 'goodguy', I was getting logged in as 'ordinaryjoe', an id that existed in both app1 and app2 (independent DBs, both sqlite3). Also, even though I was specifying 'host:app2/default/newfunc,' I was being redirected to 'host:user/login?next=newfunc', which looks like (when login doesn't fail) it ends up trying to find newfunc in app1. Being explicit about 'host:/app2/default/user/login?next=app2/default/newfunc' didn't seem to help. I finally opened a tab in a different browser, and was able to get to the right place, but it seemed like a lot of Sturm und Drang by that time. For the record, server web2py 2.15.4, python 2.7.13, aws linux; clients Firefox 58.0.2, Chrome 63.0.3239.132, on W10. Also, the successful effort was on Chrome, and today I used the dev tools to record the network activity for the form submit (I'm preparing to use curl to submit the form), and I could see from the request headers that there was session id cookie for both app1 and app2 (yes, I've used app1 on that browser, also). Should I be doing something in routes.py to make all this work better, or are the user functions problematic in the 1x web2py 2x apps scenario, or was I just a victim of browser caches? Dave S /dps -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.