[web2py] Re: Web3py

2019-05-13 Thread Massimo Di Pierro
can you please try again with the latest version? On Sunday, 12 May 2019 17:17:40 UTC-7, Scott Hunter wrote: > > Note: if the folder, translations, that is being complained about is > added, the app still can't be reached, but there is no longer an exception > reported: just the 404 page. > > -

[web2py] Re: Web3py

2019-05-13 Thread Massimo Di Pierro
Want to help: 1) need a version of this https://github.com/web2py/web3py/blob/master/applications/_scaffold/static/components/auth.html with bootstrap style for forms 2) like for login and register, need similar methods for the other actions: https://github.com/web2py/web3py/blob/master/applic

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Massimo Di Pierro
Nice. But would you agree with me that this is mostly a client side functionality? Web2py and web3py are mostly serverside frameworks. What would you want to see in web3py that helps with PWA? On Sunday, 12 May 2019 23:41:01 UTC-7, Val K wrote: > > I made one: > https://vuepydemo.pythonanywhere.

[web2py] Re: Web3py

2019-05-13 Thread 黄祥
*last commit need extra step on terminal* echo tornado >> requirements.txt mkdir applications/_dashboard/translations mkdir applications/_scaffold/databases mkdir applications/toys/databases *error traceback* $ ./web3py-start applications/ Traceback (most recent call last): File "/Users/sugizo/l

[web2py] Re: Web3py

2019-05-13 Thread 黄祥
forgot to include the logs after get the web3py started (taken from terminal) WARNING:tornado.access:404 GET /dashboard (127.0.0.1) 6.48ms WARNING:tornado.access:404 GET /favicon.ico (127.0.0.1) 2.52ms WARNING:tornado.access:404 GET /_scaffold/static/favicon.ico (127.0.0.1) 2.60ms WARNING:tornado

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Val K
You are right, this is 100% client side technology. I think we can provide a simple universal script that will show some configurable static page when offline -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://cod

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Martin Weissenboeck
A few thoughts about PWA: First: Web2py is great. But maybe the discussion should go deeper: how will the internet be used now and in the future? It will probably be used mainly by the mobile devices. With all the problems that arise from the fact that the Internet is not available everywhere and

Re: [web2py] Re: Future of web2py

2019-05-13 Thread João Matos
That is only checking if the Internet connection/db connection exists. That could be done by every web app (web2py or otherwise). That is not the definition of a PWA. >From wikipedia " Progressive web applications (PWAs) are web applications that load like regular web pages or websites but can of

[web2py] Re: web2py - didn't disconect from postgreSQL auth database (TIME_WAIT)

2019-05-13 Thread Krzysztof Jeleń
> >> I'm using web2py (Version 2.14.6-stable+timestamp.2016.05.09.19.18.48). >> > > How long have you been using this version? What OS and what front end and > what version of Python? > 3 years currently, python version is 2.7.5, Centos 7.5.1804, kernel 3.10.0 > > >> Last week I've start g

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Val K
'That could be done by every web app (web2py or otherwise).' it is not quite so, if you close regular web page (without embedded serviceWorker) and try to open it again when offline you will get nothing, I suppose. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation)

Re: [web2py] Re: Future of web2py

2019-05-13 Thread João Matos
You are correct. I though you meant keeping the app open and trying to use the database or loading another page. In the case you close the app then you would need some kind of embedded server (as I already mentioned) or serviceWorker (which I think is something lighter but similar). For the cas

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Val K
my example is not fully featured PWA, but it works offline and as I mentioned above it is possible to make that web23py application will show something better than nothing when offline -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Carlos Costa
I don't think all PWA cases must work 100% offline. For 100% offline apps you just need a server to "install" your app, and so web2py would be handy, but no more after install in client. This is not case we should aim as web2py as focused on database driven apps. Sync database may be desirable in

[web2py] Re: gmail unable to send email

2019-05-13 Thread mostwanted
hahahah* 'being marked as "EVIL"'*I really like your solution, i will give it a try as well. Mostwanted On Sunday, May 12, 2019 at 11:11:10 AM UTC+2, Dave S wrote: > > > > On Monday, May 6, 2019 at 6:49:33 AM UTC-7, Leonel Câmara wrote: >> >> If you don't send too many emails I recommend usi

[web2py] gluon.contrib.pymysql.err.Error AssertionError('Protocol error, expecting EOF',)

2019-05-13 Thread Gilad Hoshmand
Hi all, I built a join query which breaks up a field that has '|' char as separator of values to multiple rows with single values (ie. field value = '1|2|3' , rows will be multiplied with single_value_field = 1 , single_value_field = 2 etc..) Filters some rows ('Having ... ' ) Then join with a

Re: [web2py] Re: Future of web2py

2019-05-13 Thread Massimo Di Pierro
I agree. About "tools that deliver apps to the client". I once experimented with this https://github.com/mdipierro/regift It is a cordova app that can be updated from the server without reinstallation. The app keeps the state and talks to server only if available. There is a lot that can be done

[web2py] Python version in web2py console says 3.7 but 2.7 in the web console settings

2019-05-13 Thread Robert Rice
I am testing OpenCV and need version 2.7 and that is what the site version says (2.7.12). I updated the default.py for this new website and it failed due to the use of python v 2.7 classes. Whats up? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/

[web2py] RESTful service with access control

2019-05-13 Thread Jim S
Hi I'm setting up a REST service that requires authentication. I'm following the example here: http://web2py.com/books/default/chapter/29/10/services#Access-Control Here is the example with basic login: auth.settings.allow_basic_login = True @auth.requires_login() @request.restful() def api(

[web2py] Re: Could this problem in production be related to web2py?

2019-05-13 Thread Lisandro
After doing a lot of reading about uWSGI, I've discovered that "uWSGI cores are not CPU cores" (this was confirmed by unbit developers , the ones that wrote and mantain uWSGI). This makes me think that the issue I'm experiencing i

[web2py] RESTful service with access control

2019-05-13 Thread Val K
As far as I understand, basic means passing login and password in the headers and it doesn't matter if username or email is used as login, no? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/we

[web2py] Re: Web3py

2019-05-13 Thread En Ware
I also have the same errors , I installed tornado also On Monday, May 13, 2019 at 3:05:05 AM UTC-5, 黄祥 wrote: > > forgot to include the logs after get the web3py started (taken from > terminal) > WARNING:tornado.access:404 GET /dashboard (127.0.0.1) 6.48ms > WARNING:tornado.access:404 GET /favic

[web2py] Re: Web3py

2019-05-13 Thread Massimo Di Pierro
That error in the console is intentional. It is an example of what happens when there is a bug in app code. It should not prevent web3py from running. Or does it? -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https:/

[web2py] Re: RESTful service with access control

2019-05-13 Thread Jim S
Shoot, looks like my initial testing wasn't even working. I was just checking the status code which was returning 200, but didn't realize it was redirecting me to the login page. Any way i can stop that? -Jim On Monday, May 13, 2019 at 11:51:27 AM UTC-5, Val K wrote: > > As far as I understan

[web2py] Re: Web3py

2019-05-13 Thread En Ware
It did until I install tornado , but still can't access the dashboard or any of the apps. I am going to do a new git clone and try again. On Monday, May 13, 2019 at 12:29:29 PM UTC-5, Massimo Di Pierro wrote: > > That error in the console is intentional. It is an example of what happens > wh

[web2py] Re: Web3py

2019-05-13 Thread En Ware
./web3py-start applications/ ___ __ __ | / / / / __ |/___ \/ __ \ \/ / | | / / /_ / /_/ /___/ / /_/ /\ / | | /| / / __/ / __ //__ / / / / | |/ |/ / /___/ /_/ /___/ / / / / |___/|_/_/_/_/_/ /_/ It is still experimental... Dash

[web2py] Re: RESTful service with access control

2019-05-13 Thread Val K
For services I use auth.login_bare(u,p) and handmade decorator based on auth.is_logged_in() - don't forget about parens! -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Rep

[web2py] Re: RESTful service with access control

2019-05-13 Thread Val K
There is also https://github.com/web2py/web2py/blob/master/gluon/authapi.py -- 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 beca

[web2py] authapi.py

2019-05-13 Thread Tito Garrido
Hi Guys! Is there any example using authapi + jwt in any documentation? Thank you! Tito -- Linux User #387870 . _/_õ|__| ..º[ .-.___.-._| . . . . .__( o)__( o).:___ -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web

[web2py] Re: authapi.py

2019-05-13 Thread Val K
https://github.com/web2py/web2py/blob/4a90c82ee4271b2a17c187d41138a03249c14350/gluon/tools.py#L1002 https://github.com/robertop23/web2py_vuejs_vuetify/blob/master/controllers/api.py On Monday, May 13, 2019 at 10:11:31 PM UTC+3, Tito Garrido wrote: > > Hi Guys! > > Is there any example using

[web2py] setting up pscycopg2

2019-05-13 Thread Dave S
When I check Last week I ended up making the move to Postgres on the busier of my production servers, and the changeover appears to be successful (imported existing data via CSV). I was interested to see that the import preserved some gaps in the id field, and that Postgres was filling some of

[web2py] Re: Web3py

2019-05-13 Thread 黄祥
*in latest commits (100) steps will reproduce an error that make web3py won't start (error traceback reported on previous message)* git clone https://github.com/web2py/web3py cd web3py pip3 install -r requirements.txt ./web3py-start applications/ *so need an extra steps to make web3py start in la

[web2py] Re: setting up pscycopg2

2019-05-13 Thread Dave S
On Monday, May 13, 2019 at 2:31:33 PM UTC-7, Dave S wrote: > > When I check Last week I ended up making the move to Postgres on the > busier of my production servers, and the changeover appears to be > successful (imported existing data via CSV). I was interested to see that > the import pres

[web2py] Re: Web3py

2019-05-13 Thread Massimo Di Pierro
It is _dashboard not dashboard -- 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

Re: [web2py] Re: RESTful service with access control

2019-05-13 Thread Jim Steil
Val Thanks so much for the references. However, I'm really a bit lost. Using login_bare()?? Where does that come in to play? And then a custom decorator? Am I doing something wrong that is preventing the sample in the book from working? Not sure why mine is just redirecting. Any samples wou

[web2py] Password File

2019-05-13 Thread Suhas Jadhav
Hi Gurus, In my web2py application, i am connecting to two different databases. Currently, I am saving username and password in the code. I want to use a password file or some other mean. Can you please help. -- Thanks, Suhas -- Resources: - http://web2py.com - http://web2py.com/book (Documenta

Re: [web2py] Re: RESTful service with access control

2019-05-13 Thread Jim Steil
Val I just created a test app based on the code in the book and all is working as it should. Must be something else in my other app that is causing the trouble. I'll check it out later. Also looking into JWT... On Mon, May 13, 2019 at 8:38 PM Jim Steil wrote: > Val > > Thanks so much for the

[web2py] Re: Web3py

2019-05-13 Thread 黄祥
yes, you are right, my bad echo tornado >> requirements.txt or pip3 install tornado required to make web3py started while for directories creation is needed to get access to the webapp mkdir applications/_dashboard/translations mkdir applications/_scaffold/databases mkdir applications/toys/databas

[web2py] block entire app

2019-05-13 Thread lucas
hey one and all, where, in what model or controller, is the best place to place a few lines of code that captures every controller/function call in the entire app and returns a single page with a line of text and link to shuttle the viewers to another website. and what would be those few lines

[web2py] Re: Web3py

2019-05-13 Thread Massimo Di Pierro
Added tornado to requirements. My bad On Monday, 13 May 2019 20:03:35 UTC-7, 黄祥 wrote: > > yes, you are right, my bad > echo tornado >> requirements.txt > or > pip3 install tornado > required to make web3py started > > while for directories creation is needed to get access to the webapp > mkdir ap

Re: [web2py] Re: RESTful service with access control

2019-05-13 Thread Val K
One yet important moment: Do you set the view for your api? I mean, that book example will not work without response.view='generic.json' if request is not local. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://c

[web2py] new DBAPI in pydal for both web2py and web3py

2019-05-13 Thread Massimo Di Pierro
You may have missed this but there is a new functionality in PyDAL that allows you to create very powerful APIs. It is called DBAPI. It is still not 100% stable but it is working and I could use some help testing it. web3py's equivalent of appadmin will be called dbadmin (90% done) and it is bas

[web2py] Re: new DBAPI in pydal for both web2py and web3py

2019-05-13 Thread Massimo Di Pierro
For more examples look at the tests: https://github.com/web2py/pydal/blob/master/tests/dbapi.py On Monday, 13 May 2019 23:18:42 UTC-7, Massimo Di Pierro wrote: > > You may have missed this but there is a new functionality in PyDAL that > allows you to create very powerful APIs. It is called DBA

[web2py] Re: RESTful service with access control

2019-05-13 Thread Massimo Di Pierro
You may want to see my other post about the new policy based DBAPI. On Monday, 13 May 2019 09:28:11 UTC-7, Jim S wrote: > > Hi > > I'm setting up a REST service that requires authentication. I'm following > the example here: > > http://web2py.com/books/default/chapter/29/10/services#Access-Contr