Re: [web2py] Re: How do I solve this error: NameError: name 'person_id' is not defined in KPax2

2019-09-11 Thread Lovedie JC
I got this from web2py appliances apps. Just trying it out. Regards On Wed, 11 Sep 2019, 11:04 Dave S wrote: > > > On Tuesday, September 10, 2019 at 1:31:11 PM UTC-7, Maurice Waka wrote: >> >> I'm trying out a surveys app from KPax2/surveys/take_survey.. >> >> >> but got this error: >> Traceback

Re: [web2py] Re: How do I solve this error: NameError: name 'person_id' is not defined in KPax2

2019-09-12 Thread Lovedie JC
Auth.iser.id works. Just the cPickle issues. Maybe I'll be on and off asking more about it. Regards On Thu, 12 Sep 2019, 09:16 Massimo Di Pierro wrote: > wow that is a very old app. It has some good ideas but it also has bugs. > It was a proof of concept. I believe person_id in that context sho

Re: [web2py] a first py4web video tutorial - running on pythonanywhere.com

2019-09-26 Thread Lovedie JC
Great news. Py4web for mobile? On Mon, 23 Sep 2019, 08:35 Massimo Di Pierro wrote: > https://youtu.be/Wxjl_vkLAEY > > -- > Resources: > - http://web2py.com > - http://web2py.com/book (Documentation) > - http://github.com/web2py/web2py (Source code) > - https://code.google.com/p/web2py/issues/lis

Re: [web2py] No Column error

2019-11-29 Thread Lovedie JC
I think my error was due to a reserved name. I had a field called timestamp that was leading to the error. Now works well. On Wed, Nov 27, 2019, 19:01 Maurice Waka wrote: > I got this error after installing psycopg2 > > > > Traceback (most recent call last): > File "/home/mauricewaka/web2py/gl

Re: [web2py] No Column error

2019-11-30 Thread Lovedie JC
Yes I did. Thanks for the help On Sat, Nov 30, 2019, 07:45 Dave S wrote: > > > On Friday, November 29, 2019 at 1:06:01 AM UTC-8, Lovedie JC wrote: >> >> I think my error was due to a reserved name. I had a field called >> timestamp that was leading to the error. &

Re: [web2py] Database drivers available does not show psycopg2

2019-12-21 Thread Lovedie JC
Had the same issues. Found out that python was looking for the drivers in anaconda folder instead. Had to rename anaconda. Still then same problems persisted with python 3.6. I had to download the psycopg2 and put the folder in site packages or modules folder. Problem solved. Regards On Fri, Dec 2

Re: [web2py] runing my app from python 2.7.5 to 3.5.9

2019-12-30 Thread Lovedie JC
Most functions/modules will work. Some may require some code changes such as print in 2.7 is: 'print variable' But in 3.6 is a function as: 'print (variable)' Some module are deprecated or changed to different folders Depending on your needs. I did change to 3.6 with minimal changes to code.

Re: [web2py] No driver of supported ones ('psycopg2',) is available

2020-01-20 Thread Lovedie JC
I had to copy it, the folder to Web2py modules folder for it to work. You can also copy to Web2py site packages folder. Regards On Mon, Jan 20, 2020, 20:53 'Annet' via web2py-users < web2py@googlegroups.com> wrote: > Last week I upgraded my development environment from Mac OS X Mavericks - > Pyth

Re: [web2py] Re: Web2py or py4web for a brand new project

2020-01-23 Thread Lovedie JC
Is there a problem with @auth_has _permission? I intend to use it. Regards On Thu, Jan 23, 2020, 18:57 Jim S wrote: > You'll be fine with the new system I believe as long as you're not > currently using @auth.has_permission. While you can do it with py4web it > is more challenging than in web2p

Re: [web2py] web2py Newbie

2020-02-09 Thread Lovedie JC
Probably your default python is 2.7. You need to download the latest Web2py. Use python 3 since we are moving from python 2.7 For example, in terminal use : >>cd web2py Then once in the folder: >>python3 web2py.py Support for python 2.7 ended. Regards On Mon, Feb 10, 2020, 08:58 Tim Polimeni wrot

Re: [web2py] Re: ERROR on Request

2020-02-21 Thread Lovedie JC
Thanks. I switched to it. Regards On Fri, Feb 21, 2020, 06:58 Massimo Di Pierro wrote: > in py4web request is the bottlepy request. > https://bottlepy.org/docs/dev/api.html#the-request-object > There is no now. > > You can use datetime.timetime.now() > > On Tuesday, 18 February 2020 08:34:51 UTC

Re: [web2py] Re: p4web auth issues

2020-02-23 Thread Lovedie JC
Thanks. Before you replied I had tried : user = auth.get.user()[first_name] With an error.. 'first_name' is not defined Regards On Mon, Feb 24, 2020, 02:02 Val K wrote: > `auth` in py4web is no the same as in web2py > to get user-record you should > ... > def index(): > user = auth.get_user

Re: [web2py] Re: py4web posting to db

2020-03-04 Thread Lovedie JC
I just found out that the error was because I was having a null variable instead of an image in one of the lines. I still can't figure out how I can't have the Field(author, reference auth_user work. On Wed, Mar 4, 2020, 13:30 Maurice Waka wrote: > I've done some look up into the code, did some

Re: [web2py] web2py 2.19.1 is OUT

2020-03-21 Thread Lovedie JC
I've updated it. Flawless 👍 Good work. Much appreciated. Regards On Sun, Mar 22, 2020, 04:28 Christian Varas wrote: > Thanks! 🎉🎉🎉🎊 > > El El sáb, 21 de mar. de 2020 a la(s) 18:52, Massimo Di Pierro < > massimo.dipie...@gmail.com> escribió: > >> Sorry it took so long. >> >> Web2py 2.19.1 is final

Re: [web2py] Re: jQuery not working with web2py

2020-04-02 Thread Lovedie JC
I did that, without the layout.html but still getting the same effects. Regards On Thu, Apr 2, 2020, 17:42 Jim S wrote: > You are including layout.html at the top of your code snippet. > > I would suggest that you test this all by itself (remove the include of > layout.html) before trying to int

Re: [web2py] Re: jQuery not working with web2py

2020-04-02 Thread Lovedie JC
ense? > > -Jim > > > On Thu, Apr 2, 2020 at 12:45 PM Jim Steil wrote: > >> Same effects, yes, but what error messages are you seeing in the console? >> >> -Jim >> >> On Thu, Apr 2, 2020 at 9:55 AM Lovedie JC wrote: >> >>> I did that,

Re: [web2py] Which 4 or 2?

2020-04-18 Thread Lovedie JC
Check out the video tutorials on vimeo as well. They're great Regards On Sat, Apr 18, 2020, 11:11 David Swarbrick wrote: > Thank you for the encouragement, and the really useful resources > identified. > > I think I have to work through the book, and where something really is not > understandabl

Re: [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-18 Thread Lovedie JC
I once had the same error, Updated Web2py then copied the psycopg2 in the modules folder. It worked for me. Regards On Sat, Apr 18, 2020, 19:09 Valdeck Rowe wrote: > So I checked gluon/contrib and it wasn't there, so I moved it into > gluon/contrib. Restarted nginx. Still getting the same error.

Re: [web2py] Android and ios aops

2020-04-24 Thread Lovedie JC
Thanks. I had seen the SL4A some time ago but couldn't trace the instructions on how to do it. I'm more interested in a Google play store product though. Regards On Fri, Apr 24, 2020, 17:45 Christian Varas wrote: > Hi, i did this in android some years ago, you can run web2py using SL4A > and ins

Re: [web2py] Re: web2py and ubuntu 20lts

2020-05-01 Thread Lovedie JC
Let me try On Fri, May 1, 2020, 11:00 Clemens wrote: > Hi Maurice, > > obviously you're trying to execute your pythone-2-compiled code with > python 3 (Ubuntu 20 default). Have a try recompiling it with python 3.x. > > Does this solve the problem? > > Regards > Clemens > > On Friday, May 1, 202

Re: [web2py] Re: web2py and ubuntu 20lts

2020-05-01 Thread Lovedie JC
On system restart, the previous pyc files for python 2+ were deleted and it works OK. Let me observe for now. Regards On Fri, May 1, 2020, 11:26 Lovedie JC wrote: > Let me try > > On Fri, May 1, 2020, 11:00 Clemens > wrote: > >> Hi Maurice, >> >> obvious

Re: [web2py] Re: I broke something

2020-05-25 Thread Lovedie JC
I got several such errors in p3. Changing to: Except Exception as e: Works for me. On Tue, Jun 18, 2019, 19:19 Jim S wrote: > Isn't that an old except syntax that is not supported in Python 3? > > I'm thinking it should be: > > except Exception as e: > > > ...but, I'm no expert in 2 to 3 changes

Re: [web2py] Any alternative to installing web2py on laptop

2020-07-19 Thread Warwick JC
I also just use a local folder to run Web2py. You can still use the laptop by downloading the source file and unpacking it to a local folder. Regards On Mon, Jul 20, 2020, 08:32 AGRogers wrote: > Sure. pythonanywhere.com is where I started. > > Maybe it can run from a USB stick? I think it is pr

[web2py] login expiration time

2020-07-23 Thread Warwick JC
Hello. I have a web2py html page (e.g. idex.html) that has another page in iframe within the app. After session timeout, I get redirected back to the login page which works at the iframe page and not the main page. I used this in the model.py: auth.settings.expiration = 1800 The problem is

Re: [web2py] Re: login expiration time

2020-07-24 Thread Warwick JC
Thanks. Is it wrong to have iframe pages from the same app? Regards On Fri, 24 Jul 2020 at 15:20, villas wrote: > If you are using an iframe to display a page from the same app, I have > the impression that your design might be wrong. You will probably find a > better way after you give this a

Re: [web2py] Re: login expiration time

2020-07-25 Thread Warwick JC
24 July 2020 23:21:03 UTC+3, Warwick JC wrote: > > Thanks. > Is it wrong to have iframe pages from the same app? > Regards > > On Fri, 24 Jul 2020 at 15:20, villas wrote: > >> If you are using an iframe to display a page from the same app, I have >> the impression

[web2py] How do I prevent going back to previous page after user is logged out?

2020-07-27 Thread Warwick JC
I have a page that when logging in from a previous logout, the login page redirects back to the same page. I want to have a default redirect to the index page instead. Using auth.settings.login_next = URL('default','index') does not help. 1. Is there a better way out in js or some form o

Re: [web2py] Re: login expiration time

2020-07-28 Thread Warwick JC
nt into > your website, e.g. advertisements. > > The iframe allows a method of ceding control of a portion of your screen > to be taken over and used by 'someone else' e.g. perhaps a credit card > payment gateway, a PDF viewer, or simply pages from other websites. > >

Re: [web2py] Re: How do I prevent going back to previous page after user is logged out?

2020-08-02 Thread Warwick JC
Hi Thanks for this. I put these functions in the model.py, I hope its correct. def __on_login(): redirect(URL('index')) return None def __on_logout(): redirect(URL('index')) return None On Fri, 31 Jul 2020 at 11:49, 'Annet' via web2py-users < web2py@googlegroups.com> wrote: > Wh

Re: [web2py] Re: How do I prevent going back to previous page after user is logged out?

2020-08-03 Thread Warwick JC
Thanks guys. They both work well. Regards On Mon, Aug 3, 2020, 21:01 Rahul wrote: > Another simple way is -- > To pop out session variables like in code below for all the login session > variables and redirect the user wherer-ever you want them to be. > This way since no valid session exists th

[web2py] making url shorter in web2py and google appengine

2020-08-06 Thread Warwick JC
Hello, I followed this example on URL shortening. I wonder how can I do with multiple controllers in the app. Will the example below be pythonic? routers = dict( BASE = dict( default_

[web2py] How to shorten URL name for web2py with multiple controllers

2020-08-06 Thread Warwick JC
Hello. I only note that this works only for the index page. routers = dict( # base router BASE=dict( default_application='init', ), # app specific router rivelar=dict( default_controller='default', default_function='index' ) ) I would also like to sho

Re: [web2py] Anyone in or near Barcelona?

2020-10-16 Thread Warwick JC
I once had a project with: nick.d.kreiss...@gmail.com Then he was in Barcelona On Thu, Oct 15, 2020, 15:43 i.r...@appichar.com.au wrote: > Hi - I'm looking for someone based in or around Barcelona with > Python/web2py experience who might be able to help with a couple of > projects I've built /

[web2py] Hide multiple controller names and functions.

2020-11-23 Thread Warwick JC
Following on this , is there a way one can do the same with multiple controllers and thier functions? For me it only works for one controller. Regards -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github

Re: [web2py] web2py 2.21.1 is OUT

2020-11-28 Thread Warwick JC
Thank you for your great product. Regards On Sat, Nov 28, 2020, 07:22 Massimo Di Pierro wrote: > > Hello everybody, > > first of all my apologies to you all. I have been absent from this list > for some time, mostly because busy with py4web. > > I made a new release (2.21.1) of web2py which incl

[web2py] How to customize email settings.

2020-12-02 Thread Warwick JC
I recently successfully used the configured email settings as follows: mail = auth.settings.mailer mail.settings.server = 'smtp.gmail.com:587' mail.settings.sender = 'usern...@gmail.com' auth.settings.registration_requires_verification = True I noted that the email arrived with the sender name in

Re: [web2py] Module error

2020-12-07 Thread Warwick JC
Easier and crazy way I do is install the requests module in modules folder or site packages. On Mon, Dec 7, 2020, 16:51 Gaël Princivalle wrote: > > Hello. > > Moving an app to another server I've this error: > No module named > applications.myapp.modules.requests > > Of course I've the modules

Re: [web2py] Module error

2020-12-07 Thread Warwick JC
I had the same issue with pygal. After putting the pygal moduIe in the modules folder all was sorted. On Mon, Dec 7, 2020, 18:43 Gaël Princivalle wrote: > That's crazy for sure. > The modules are in the modules folder . > I don't understand why they don't appear in the modules list and why > the

<    1   2