[web2py] MySQL cache issues

2020-04-15 Thread Joel Samuelsson
Got help earlier with keeping my database connections alive between requests: https://groups.google.com/forum/#!topic/web2py/QraWtFvlqf8 I put my databases in a module like this: class Databases(): _td_db = None @staticmethod def getTDDB(): dbCreated = False if Databases._td_db

[web2py] Re: Getting an error that ends in "No driver of supported ones %s is available" % str(self.drivers) RuntimeError: No driver of supported ones ('psycopg2',) is available

2020-04-15 Thread Dave S
On Tuesday, April 14, 2020 at 4:29:12 PM UTC-7, Valdeck Rowe wrote: > > Also tried installing psycopg2-binary to no avail > > Installed in the system python, or locally in the web2py folders? What does your PYTHONPATH variable look like? /dps > On Tuesday, April 14, 2020 at 12:58:14 PM UTC-5

[web2py] Re: Field('upload') : problem with file name

2020-04-15 Thread Andrew Rogers
>>> Field(name, 'upload', size=200) I think 'size' should be 'length'. The latter worked for me and the former didn't. On Monday, 20 July 2015 16:24:24 UTC+10, Massimo Di Pierro wrote: > This is handled by web2py. The filenames are truncated according to the > size of the uploadfield. This defa

[web2py] Re: Getting an error that ends in "No driver of supported ones %s is available" % str(self.drivers) RuntimeError: No driver of supported ones ('psycopg2',) is available

2020-04-15 Thread Valdeck Rowe
PYTHONPATH is blank On Wednesday, April 15, 2020 at 4:26:31 AM UTC-5, Dave S wrote: > > > > On Tuesday, April 14, 2020 at 4:29:12 PM UTC-7, Valdeck Rowe wrote: >> >> Also tried installing psycopg2-binary to no avail >> >> > Installed in the system python, or locally in the web2py folders? > > What

[web2py] Web2py routes domains do not work for me anymore

2020-04-15 Thread Anatoli Hristov
Hello, I used to use the routes.py in the root of web2py folder where after deployed a new server, and restored the web apps, it shows (Internal server error): This is my routes.py > *routers = dict(* > *BASE = dict(* > *domains = {* > *'mydomain.com' : 'myapp',* > *

[web2py] Re: Web2py routes domains do not work for me anymore

2020-04-15 Thread Dave S
On Wednesday, April 15, 2020 at 4:05:48 PM UTC-7, Anatoli Hristov wrote: > > Hello, > > I used to use the routes.py in the root of web2py folder where after > deployed a new server, and restored the web apps, it shows (Internal server > error): > > This is my routes.py > > >> *routers = dict(*

[web2py] Re: Web2py routes domains do not work for me anymore

2020-04-15 Thread Anatoli Hristov
Thank you Dave, There are no error logs from this :( It just keep showing internal server error until I delete the routes,py from the root folder. Sorry for topping up the post, I cannot remove it anymore, shall I delete the post? Thanks On Thursday, 16 April 2020 01:09:17 UTC+2, Dave S wrot

[web2py] Re: Getting an error that ends in "No driver of supported ones %s is available" % str(self.drivers) RuntimeError: No driver of supported ones ('psycopg2',) is available

2020-04-15 Thread Dave S
On Wednesday, April 15, 2020 at 11:31:56 AM UTC-7, Valdeck Rowe wrote: > > PYTHONPATH is blank > > So is mine, as it turns out (unless it's set in the nginx environment). On my aws system, I seem to have the psycopg2 directory under gluon/contrib /dps > On Wednesday, April 15, 2020 at 4:26

[web2py] Re: Web2py routes domains do not work for me anymore

2020-04-15 Thread Anatoli Hristov
Found some log in nginx access.log: 10.63.238.14 - - [15/Apr/2020:23:18:00 +] "GET / HTTP/1.0" 500 21 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.163 Safari/537.36" 10.63.238.14 - - [15/Apr/2020:23:18:01 +] "GET /favicon.ico HTTP

[web2py] Re: Web2py routes domains do not work for me anymore

2020-04-15 Thread Dave S
On Wednesday, April 15, 2020 at 4:20:18 PM UTC-7, Anatoli Hristov wrote: > > Found some log in nginx access.log: > > 10.63.238.14 - - [15/Apr/2020:23:18:00 +] "GET / HTTP/1.0" 500 21 "-" > "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like > Gecko) Chrome/80.0.3987.1

[web2py] Re: Getting an error that ends in "No driver of supported ones %s is available" % str(self.drivers) RuntimeError: No driver of supported ones ('psycopg2',) is available

2020-04-15 Thread Valdeck Rowe
I've copied the psycopg2 package over to the web2py/site-packages folder, added the packages folder to the path. Still nothing On Tuesday, April 14, 2020 at 12:58:14 PM UTC-5, Valdeck Rowe wrote: > > Greetings, > > Got this error on a production Centos 7 box (on an intranet) after running > the

[web2py] Re: Web2py routes domains do not work for me anymore

2020-04-15 Thread Anatoli Hristov
nothing in the web2py log file, file not even created! I don't know how to define the favico.ico in nginx. However, if I delete the routes.py everything works, but I need to define domains for my apps! On Thursday, 16 April 2020 01:38:28 UTC+2, Dave S wrote: > > > > On Wednesday, April 15, 2020