[web2py] web2py 2.25.1 - bug when running interactive shell?

2023-10-27 Thread Tom Clerckx
I believe web2py/gluon/shell.py", line 238 should use os.path.*abspath* instead of *absdir*? Unpacked and ran a clean version of web2py: command: python web2py.py -B -S welcome -M web2py Web Framework Created by Massimo Di Pierro, Copyright 2007-2023 Version

[web2py] Re: app not loading external python library

2023-10-27 Thread Tom Clerckx
I think this is the same issue as was discussed a few months ago: See this thread: https://groups.google.com/g/web2py/c/xYVWpDGLuzY/m/t9sBabWOAgAJ Seems some issue between the custom importer and the urllib3 module. Can you try once more, but also explicitly pip install *urllib3_secure_extra

[web2py] Re: uwsgi with web2py hard crash/locking with nginx

2023-10-17 Thread Tom Clerckx
Maybe you should review the 'high calculation/high plotly' pages for memory usage? As the 'OOM killer' kicked in, it looks like the process is using too much memory. One thing to verify this is to monitor the VmRSS of the processes involved (VmRSS is one of the fields in the output when you do

Re: [web2py] Why am I getting "unable to import requests" in web2py even though requests is accessible directly through python

2023-05-30 Thread Tom Clerckx
;>>>>>>> getting web2py: >>>>>>>> >>>>>>>> git clone https://github.com/web2py/web2py.git >>>>>>>> cd web2py/ >>>>>>>> git submodule update --init --recursive >&g

Re: [web2py] Why am I getting "unable to import requests" in web2py even though requests is accessible directly through python

2023-05-27 Thread Tom Clerckx
d to get rid of all pyc files and or to uninstall and > reinstall requests? > > Il giorno sab 27 mag 2023 alle ore 14:20 Tom Clerckx > ha scritto: > >> See below. In both tests the requests library is in the last element of >> the path. >> >> TEST1, plain p

Re: [web2py] Why am I getting "unable to import requests" in web2py even though requests is accessible directly through python

2023-05-27 Thread Tom Clerckx
See below. In both tests the requests library is in the last element of the path. TEST1, plain python shell - import OK (test) tclerckx@stark:~/temp/test$ python Python 3.10.6 (main, Jan 14 2023, 23:48:13) [GCC 11.3.0] on linux Type "help", "copyright", "credits" or "license" for more

[web2py] Re: Why am I getting "unable to import requests" in web2py even though requests is accessible directly through python

2023-05-26 Thread Tom Clerckx
Good point, I'm curious as well. I did a few experiments and I noticed that: Running a virtualenv built on python *2.7.18* and using web2py (python2 version) "Version 2.24.1-stable+timestamp.2023.03.23.05.07.17", the import goes *OK *within a web2py shell. Running a virtualenv built on python

[web2py] Re: Web2py deployment on a local so all computers in the network can acess it

2022-08-24 Thread Tom Clerckx
Not sure what information you're looking for. There is no dependency on having an internet connection to deploy your web2py service. With respect to deployment itself, you can follow the deployment recipes in the web2py manual. Tom. On Wednesday, August 24, 2022 at 11:49:13 AM UTC+2

[web2py] Re: Bug in gluon/scheduler.py

2022-08-20 Thread Tom Clerckx
: > On Monday, August 8, 2022 at 3:50:26 AM UTC-7 Tom Clerckx wrote: > >> Version: >> Version 2.22.5-stable+timestamp.2022.06.04.18.13.51 >> >> There is a problem with the calculation of next_run_time in >> gluon/scheduler.py at line 1024 >> >> It calcula

[web2py] Bug in gluon/scheduler.py

2022-08-08 Thread Tom Clerckx
Version: Version 2.22.5-stable+timestamp.2022.06.04.18.13.51 There is a problem with the calculation of next_run_time in gluon/scheduler.py at line 1024 It calculates: steps = secondspassed // task.period + 1 However, there is no check done for task.period being 0 This can cause the following

[web2py] About migrate and fake_migrate

2022-03-16 Thread Tom Clerckx
I was a bit confused about the explanation of the fake_migrate option in the web2py documentation. After some experimenting, I wrote up the following information for myself, just sharing it here with you. Maybe someone can merge this information in the web2py documentation, if you think it

[web2py] Re: Why web2py App performance has degraded all of sudden with SQLLITE

2021-11-08 Thread Tom Clerckx
Hi Sandeep, A bit a late reply, but it may be useful for someone later-on. I recently had the exact same issue, quite suddenly, things started to become slow. Here's what I did to solve it: *First thing to do:* make a backup of your project! *Second thing* to do is to vacuum your db, which

[web2py] Re: SQLFORM.grid and user_signature - unexpected behavior

2021-05-24 Thread Tom Clerckx
Can someone confirm my reasoning... or correct it if it's wrong? Thanks, Tom. On Monday, May 10, 2021 at 3:22:24 PM UTC+2 Tom Clerckx wrote: > I was running into some issue with SQLFORM.grid and after going through > the code, I realized that the grid does not include request.var

[web2py] SQLFORM.grid and user_signature - unexpected behavior

2021-05-10 Thread Tom Clerckx
I was running into some issue with SQLFORM.grid and after going through the code, I realized that the grid does not include request.vars when calculating the URL signature (ref: v2.21.1, gluon/sqlhtml.py @ 2440). Please correct me if I would be wrong,... else it may be useful to add

Re: [web2py] Re: Update dropdown list in SQLFORM.grid based on selection in another dropdown list

2020-11-25 Thread Tom Clerckx
> wrapper.components.extend([select_widget, form_loader_div, > activator_button, jq_script]) > return wrapper > > > > > > ___ > *www.TenOutOfTen.org* <https://www.TenOutOfTen.org> > roge...@gmail.com >

[web2py] Re: Update dropdown list in SQLFORM.grid based on selection in another dropdown list

2020-11-20 Thread Tom Clerckx
form-events onchange/onselect/...) could be achieved when e.g. creating the form, so that you can do it in python instead of having to add the javascript functions. On Friday, November 13, 2020 at 3:53:23 PM UTC+1 Tom Clerckx wrote: > Hi, > > Considering the sample code below. > I h

[web2py] Update dropdown list in SQLFORM.grid based on selection in another dropdown list

2020-11-13 Thread Tom Clerckx
Hi, Considering the sample code below. I have manually populated the books table with a number of books for different genres. Now I can create an entry in the shelves table, using the SQLFORM.grid The shelve_items will be shown as a dropdown list with the books that I've added What I would

[web2py] Re: web2py scripts (homemade task queues) and python2 compatibility

2019-07-16 Thread Tom Clerckx
That's clear, thanks for the update. On Tuesday, July 16, 2019 at 6:48:41 PM UTC+2, Leonel Câmara wrote: > > You're right, you must use the print function because web2py now has a " > from __future__ import print_function" which forces you to use the print > function even in python2 > --

Re: [web2py] web2py scripts (homemade task queues) and python2 compatibility

2019-07-11 Thread Tom Clerckx
Anyone else that can shed some light on this? On Friday, July 5, 2019 at 3:01:11 PM UTC+2, Tom Clerckx wrote: > > Hi Nico, > > I tried explicitly with python2.7, by executing: > python2.7 web2py.py -S examples -M -R > applications/examples/private/script01.py > > On a

Re: [web2py] web2py scripts (homemade task queues) and python2 compatibility

2019-07-05 Thread Tom Clerckx
> Il giorno gio 4 lug 2019 alle ore 17:41 Tom Clerckx > ha scritto: > >> Can anyone confirm that backward compatibility with python2 is broken >> with respect to web2py scripts (or homemade task queueus)? >> I just downloaded version "2.18.5-stable+timestamp.20

[web2py] web2py scripts (homemade task queues) and python2 compatibility

2019-07-04 Thread Tom Clerckx
Can anyone confirm that backward compatibility with python2 is broken with respect to web2py scripts (or homemade task queueus)? I just downloaded version "2.18.5-stable+timestamp.2019.04.08.04.22.03" and it looks like the python3 print() function must be used. Is there any plan to fix this? If

[web2py] Re: Compile controller and module files only

2017-10-09 Thread Tom Clerckx
Update: It works fine on the latest web2py release - that works for me. Thanks. On Monday, October 9, 2017 at 10:26:20 AM UTC+2, Tom Clerckx wrote: > > That does not seem to work for me I'm getting an "invalid view" error > after removing the compiled view files &g

[web2py] Re: Compile controller and module files only

2017-10-09 Thread Tom Clerckx
2017 at 4:10:57 AM UTC-4, Tom Clerckx wrote: >> >> Is it possible to compile an application, but keep the views and the CSS >> 'uncompiled'? >> The idea is that other people can change the look and feel without having >> access to the code of the controllers and

[web2py] Compile controller and module files only

2017-10-06 Thread Tom Clerckx
Is it possible to compile an application, but keep the views and the CSS 'uncompiled'? The idea is that other people can change the look and feel without having access to the code of the controllers and the models. Best regards, Tom. -- Resources: - http://web2py.com - http://web2py.com/book

[web2py] Suggestion to add in documantation about reference fields

2017-05-24 Thread Tom Clerckx
The web2py documentation indicates that a reference field has the following default validator: IS_IN_DB(db, table.field, format) I suggest the default validator to be described as: IS_IN_DB(db, table._id, table._format) If you use any other field besides *table._id* in the validator, this

[web2py] Documentation: update requires writable=False

2015-10-15 Thread Tom Clerckx
Today I was struggling with why the following did not work for me in one of my tables: Field('modified_on', 'datetime', default=request.now, update=request.now) After some fiddling I found that writable=False must be explicitly added for this to work properly. --> Field('modified_on',

[web2py] Re: Team of admin/devellopers with different permissions

2015-03-28 Thread Tom Clerckx
You can always create multiple instances of web2py (each with their own applications directory). But for developers, wouldn't it be easier if they just have there local version of web2py and the application they're working on and use subversion/git/or any other version control system to check

[web2py] Re: import_from_csv_file and id_map={}

2015-03-17 Thread Tom Clerckx
Thanks. I will try to make some time and contribute in that way. Note: You may want to update the link to your profile on http://web2py.com/init/default/who -- it results in a page not found. Best regards, Tom. On Wednesday, March 11, 2015 at 7:07:04 PM UTC+1, Tom Clerckx wrote: I recently

[web2py] import_from_csv_file and id_map={}

2015-03-11 Thread Tom Clerckx
I recently learned (by searching through the google-group) the usefulness of the id_map={} parameter in the db.import_from_csv_file function. I was wondering why this is not included in the documentation of web2py? Is this on the 'todo' list or is there another reason why it is not included?

[web2py] TV Centric websites

2014-07-11 Thread Tom Clerckx
Hi all, I've been working with web2py for a few months now and I must say: I'm a big fan. Nowadays, I'm looking more into building TV-centric sites and I was wondering if this is/will be supported in web2py. I'm talking about websites that you can directly load on the browser of a TV or set

[web2py] Re: Undesired redirect to other page after submitting a form

2014-06-26 Thread Tom Clerckx
Sorry being persistent on this, but has somebody any idea why the observed behavior is in place? Best regards, Tom. On Thursday, June 19, 2014 9:46:06 AM UTC+2, Tom Clerckx wrote: Hi, I have some undesired behavior in my app that I was able to resolve, but I would like to understand what

[web2py] Re: Undesired redirect to other page after submitting a form

2014-06-23 Thread Tom Clerckx
that the link associated to the redirect after submitting a form is influenced by using the browser's back-button in the case when no formname paramater is used in the grid. Best regards, Tom. On Thursday, June 19, 2014 9:46:06 AM UTC+2, Tom Clerckx wrote: Hi, I have some undesired behavior in my app

[web2py] Undesired redirect to other page after submitting a form

2014-06-19 Thread Tom Clerckx
Hi, I have some undesired behavior in my app that I was able to resolve, but I would like to understand what goes wrong. I could easily reproduce the problem with a simple test-application, containing two pages and two forms (I'm skipping the boilerplate code that is created when making a new

[web2py] Scheduler: next_run_time is initially set to time-date of scheduling

2014-05-12 Thread Tom Clerckx
Hi, When adding a new task via queue_task, the next_run_time is initially set to the time the task is added to the queue. Is there a specific reason for this and is there a way to set the first_run_time correctly immediately when adding a new task to the queue? I would expect that the

[web2py] Re: 'reference auth_user' in Data base tables?

2014-04-02 Thread Tom Clerckx
auth_user is a table used in web2py with respect to access control. You'll find a good overview about this on: http://web2py.com/books/default/chapter/29/09/access-control?search=auth_user Best regards, Tom. On Tuesday, April 1, 2014 8:01:20 PM UTC+2, Shubham Rathi wrote: Hi, I am a novice to

[web2py] Re: Keep menu floating on top

2014-03-31 Thread Tom Clerckx
Fantastic! Thanks for the responses! Best regards, Tom. On Thursday, March 27, 2014 4:50:29 PM UTC+1, Tom Clerckx wrote: Is there an easy way to keep the menu 'floating' on top. I.e. when a user scrolls down that the menu stays visible at the top of the page Best regards, Tom

[web2py] Keep menu floating on top

2014-03-27 Thread Tom Clerckx
Is there an easy way to keep the menu 'floating' on top. I.e. when a user scrolls down that the menu stays visible at the top of the page Best regards, Tom. -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) -

[web2py] Book - some pictures don't show

2014-03-12 Thread Tom Clerckx
I was browsing through the web2py online book and noticed that some pictures were not rendering in the browser. Looking a bit deeper into it, I noticed that it concerns picture links over HTTPS and that the certificate is not valid. Example: On