web2py -> py4web

445 views
Skip to first unread message

Massimo Di Pierro

unread,
Jul 14, 2024, 2:10:05 AM7/14/24
to web2py-users
Hello everybody,

You may have noticed I am not very active on this mailing list. That is mostly because I have been concentrating my energy on py4web which I think is must more modern and faster than web2py.

Once again I want to encourage you to move.
If you look at this page


You will find it to be very familiar:
- has an admin interface (called _dashboard)
- has an dbadmin interface
- same pyDAL
- same template language
- same helpers
- same session interface
- similar but better Form
- similar but better Grid (still evolving)
- different request object but compatible with bottlepy
- different auth logic but support for more Oauth2 services (github, okta, facebook, etc.)
- different but similar background scheduler

Here are some instructions about how to move from web2py to py4web

web2py currently works for python2.7 and python3.7+ but they are using a frozen version of pydal. This no longer works on Google App Engine. So how do we fix it?

I am considering the following:
- freezing web2py for Python 2.7 and stopping support.
- continuing limited support of web2py for python3.7+ and specifically upgrade pydal for the lastest. 
- upgrade pydal so that it continues to work on Google App Engine for both web2py and py4web.

My questions are: Is this worth it? Have people moved from python2.7 to 3.7+ already? Are people here interested in continuing to use web2py with GAE?
 

Massimo



Clemens

unread,
Jul 14, 2024, 8:11:23 AM7/14/24
to web2py-users
Hello Massimo,

I'm a vital web2py user with a 3 systems in production. I've moved to python 3.7+ (currently 3.8) a long time ago.  I'm using postgres as database, thus for me GAE would not be relevant.

But I'm really interested in any support and security updates of web2py.

I would like to migrate to py4web. The only but big obstacle is time. As soon as I find the time I'm gonna move to py4web.

Thanks a lot for web2py and your work!

Best regards
Clemens


Raul Monares

unread,
Jul 14, 2024, 10:25:26 PM7/14/24
to web2py-users
Hi Massimo
I have several web2py applications in production. Big systems that would be difficult to move to py4web as they are growing all the time. But we're using Python 3.8.

Also, GAE is not relevant to us

Web2py has been fantastic. 

Brian M

unread,
Jul 16, 2024, 1:58:28 AM7/16/24
to web2py-users
I have a larger web2py app that would be a chore to migrate - hard to justify the time without clear incentives. It’s running Python 3.10 and not on GAE. Would be nice if there was at least some security updates.

Christian Varas

unread,
Jul 16, 2024, 2:15:49 AM7/16/24
to web...@googlegroups.com
Hi Massimo,
In my case I have still one app in production using web2py, I haven’t migrated yet because is quite big. For the rest of my apps, are all migrated to py4web and they work so much faster :).

In my opinion, drop the support of python 2.7 is recommended to avoid security issues, and also to minimize the work load of maintenance.

For web2py, maybe it is better just do bug fixes and no more upgrades. Web2py is an amazing framework that work out of the box. But Py4web is just better !

I don’t use GAE with web2py, I’ve always used in a VPS.

Thanks you  and all the team behind. 🍻

Chris.
--
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+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/6794728c-4c38-4826-ad07-d7b9827d0585n%40googlegroups.com.

Dave S

unread,
Jul 17, 2024, 2:16:03 AM7/17/24
to web2py-users
On Saturday, July 13, 2024 at 7:10:05 PM UTC-7 Massimo Di Pierro wrote:
Hello everybody,

You may have noticed I am not very active on this mailing list. That is mostly because I have been concentrating my energy on py4web which I think is must more modern and faster than web2py.

Once again I want to encourage you to move.


I am interested in moving, but I keep leaving corners on my tuits.  I don't seem to get them round.

BTW, does the javascript for the views have support for a) session storage and b) identifying tabs?
 
[...] 
web2py currently works for python2.7 and python3.7+ but they are using a frozen version of pydal. This no longer works on Google App Engine. So how do we fix it?

I am considering the following:
- freezing web2py for Python 2.7 and stopping support.
- continuing limited support of web2py for python3.7+ and specifically upgrade pydal for the lastest. 
- upgrade pydal so that it continues to work on Google App Engine for both web2py and py4web.

My questions are: Is this worth it? Have people moved from python2.7 to 3.7+ already? Are people here interested in continuing to use web2py with GAE?
 

Massimo

I'm no longer supporting a production instance of a web2py app  but I have a small public hobby app on digital ocean (python reasonably current 3.x), and some personal toy apps which I maybe will make somewhat useful for other people.  The toys are running on 3.10.7 on windows using the source package (still on 2.22.5 for the moment).

I've been meaning to file a bug report; one of the tuits is supposed to be for writing up the details, but basically at some point in version history the admin panel stopped sending all the required info needed to make the "next 100" button work.  The resulting page has an empty query box, an error message "cannot be empty", and a url like "[...]/appadmin/select/db?start=100".  This issue seems to have been in since at least 2.21.x, maybe longer.

I've very much enjoyed using web2py over the years, beginning with a development lab application for controlling test equipment.  I had a need for SOAP, and whatever package I used led me to web2py (likely pysimplesoap, but I don't have my lab notes since that lab was closed).  Eventually I was using web2py for providing a repository for customer dumps used by the support team.  And of course, it grew features like being  an update server for product firmware and applications.  Ah, fun.

I keep reading the py4web Google Group, so I have some idea of what goes on with the New Kid, but still working from my comfort zone.

Dave S
/dps


Mitsuhiro TSUDA

unread,
Jul 17, 2024, 3:48:16 AM7/17/24
to web...@googlegroups.com
Hello Massimo.

I am currently using the latest version of web2py with Python 3.7+ for more than a few services.
Thanks to you and the web2py community.

I have been using web2py for a long time.
But I have never used web2py with GAE.

I am interested in py4web and think I need to migrate from web2py, but that may still take a couple of years.

So I would appreciate it if you could provide web2py support for a little while longer.

Best regards
Mitsuhiro Tsuda



2024年7月14日(日) 11:10 Massimo Di Pierro <massimo....@gmail.com>:
--
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+un...@googlegroups.com.


--
===============================
津田光弘@イパレット
E-Mail: mts...@ipallet.org
Tel : 06-6845-2130

Massimo Di Pierro

unread,
Jul 17, 2024, 3:49:44 AM7/17/24
to web2py-users
It is very encouraging to know people have moved to python 3. :-)

Carlos Correia

unread,
Jul 17, 2024, 5:43:02 AM7/17/24
to web...@googlegroups.com
Hi,

Moving to Python 3 is a must!

As for Web2py I have several servers using it (one of them is an ERP) and I don't know when I will have time to move them to Py4web, so I beg you not to drop Web2py support.

Best regards,
Carlos

Às 04:49 de 17/07/24, Massimo Di Pierro escreveu:
--
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+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/864dbbf4-e98e-4efe-a225-e28546e071afn%40googlegroups.com.


-- 
Com os melhores cumprimentos,

Carlos Correia
=========================
MEMÓRIA PERSISTENTE
GSM:  917 157 146 (Signal)
e-mail: ge...@memoriapersistente.pt
URL: http://www.memoriapersistente.pt

Rowdy

unread,
Jul 17, 2024, 6:17:49 AM7/17/24
to web...@googlegroups.com
On 14/7/2024 12:10 pm, Massimo Di Pierro wrote:
> Hello everybody,
>
> You may have noticed I am not very active on this mailing list. That is
> mostly because I have been concentrating my energy on py4web which I
> think is must more modern and faster than web2py.
>
> Once again I want to encourage you to move.

Hi,

At work we have moved away from a web2py solution to a Java solution.

At home I still have a couple of small web2py apps running with Python 2
under Docker. No plans to update at this stage (to py4web or Python 3 -
the apps work fine as they are).

On the py4web GitHub page, in the "Tell me more" section, it notes:

"this is a work in progress and not stable yet but close to being stable"

Is that still the case?

Thanks for a great framework!

Rowdy


Jim S

unread,
Jul 17, 2024, 1:36:39 PM7/17/24
to web2py-users
I have moved most everything to py4web except for 3 big apps. However, we are migrating our ERP to Odoo and then these web2py apps will no longer be needed. Hope to have Python 2.7 support in web2py through March of 2025. We should be off by then. That being said, I doubt I'll be downloading/installing anything between now and then. I have working versions around I can use if you drop 2.7 support.

-Jim

Bruce Young

unread,
Jul 17, 2024, 9:13:21 PM7/17/24
to web2py-users
I'm using web2py for several projects. Thanks for everything.
Moved to Python 3.11
Never used GAE
Hopefully we will still get security updated for a while.
Haven't moved to py4web because of lack of time, and frankly partly because of the admin interface. It's hard to get used to after web2py.

Bruce

On Saturday, July 13, 2024 at 7:10:05 PM UTC-7 Massimo Di Pierro wrote:

xgp.l...@gmail.com

unread,
Jul 18, 2024, 1:27:29 PM7/18/24
to web2py-users
Hi Massimo.

At the moment I haven't moved to py4web. I would like you to consider support for web2py until python 3.13 at least. I understand the hard work it takes, but keep in mind improvements on newer versions of python are worth it.

Only using python 3.10+
Not using GAE.


Thanks your hard work always.

Massimo Di Pierro

unread,
Jul 22, 2024, 3:47:01 AM7/22/24
to web2py-users
Not true anymore. I will fix that.

Chitti Siva

unread,
Jul 22, 2024, 4:23:40 AM7/22/24
to web...@googlegroups.com

Hi,

Why are you adding in this mail loop and why you reply on this mail. Please remove my mail in this mail loop.

Thank & Regards,
Siva Chitti.


--
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+un...@googlegroups.com.

Gaël Princivalle

unread,
Jul 22, 2024, 4:23:40 AM7/22/24
to web2py-users
Hello Massimo.

I'm still using for 5 Web2py applications with Python 2.7.
Developing is 2% of my time work, so I need a platform reliable and simple, Web2py is perfect for that.

I must begin a new application and I'll do it with py4web.

Thanks Massimo and to all the guys that have supported Web2py.
Anyway I hope to have in future some Web2py support if needed.

Massimo Di Pierro

unread,
Jul 22, 2024, 4:25:01 AM7/22/24
to web2py-users
I encourage you at least to try run it to python 3 (probably only need to change the print statements if any at all).

Massimo Di Pierro

unread,
Jul 22, 2024, 4:25:16 AM7/22/24
to web2py-users
I encourage you at least to try run it to python 3 (probably only need to change the print statements if any at all).

On Sunday 21 July 2024 at 21:23:40 UTC-7 gaelpri...@gmail.com wrote:

Peter

unread,
Aug 25, 2024, 3:34:56 PM8/25/24
to web2py-users
I am not a professional developer and I understand others have to consider far greater risks in terms of any possible impact of errors and downtime but I wanted to add my two pence (cents) worth  regarding my experience of upgrading to web2py to Python3!
  
In 2016/17 I developed a web2py app for a family member to manage activities, invoices, payments and more for a small business (sql db, outgoing sms, pdf invoices/receipts... and  hosted on pythonanywhere.com).  The app has been in use ever since with additions and modifications being made periodically. In November 2022 I migrated the app to a new server (US to EU but still pythonanywhere) and took the opportunity to upgrade to python3. I found the upgrade to be a relatively painless exercise.  As Massimo mentioned there were some print statement errors and two maybe three others that popped up.  I found fixes for each error easily and they were quickly corrected.

Many thanks again Massimo and to all the support community for all the work put in to web2py and py4web!
 
Lastly, for what its worth, I have found py4web a bit more advanced/intimidating to get started with but still would love to get something useful up and running... 2025 might be the year!

Peter

Massimo Di Pierro

unread,
Sep 15, 2024, 11:18:51 PM9/15/24
to web2py-users
I very much appreciate this kind of feedback. My support of web2py has been slow but it has not needed much.
The fact is, if you are using python 2.7 with web2py my ability to improve web2py is limited by the python version before anything else.
Moving from web2py + 2.7 to web2py + 3.11 is a relatively small change for users.

I would very like to understand better how we can make py4web better and easier than web2py.

Alexei Vinidiktov

unread,
Dec 2, 2024, 3:53:17 AM12/2/24
to web2py-users
Hello Massimo, 

Since web2py is very very slow (according to a benchmark I've seen), I'm interested in moving to py4web but I'm not sure how to handle the transition.

My web2py app is used as a service layer communicating with the JavaScript frontend via json-rpc.
It uses web2py JWT tokens for auth.

How can I handle the same architecture in py4web?

Massimo Di Pierro

unread,
Dec 2, 2024, 6:01:43 AM12/2/24
to web2py-users
If you can provide a minimalist example of code you want to port, I can help convert it.

Alexei Vinidiktov

unread,
Dec 2, 2024, 2:25:18 PM12/2/24
to web2py-users
Basically, something like this (and I need to be able to provide sign up,  sign in, change password, etc for users via an api - json-rpc or REST):

myjwt = AuthJWT(auth, secret_key='SecretKey', expiration=3000000)

@cors_allow
@catch303
@myjwt.allows_jwt()
@auth.requires_login()
def call():
    session.forget()
    return service()

@service.jsonrpc2
def create(lesson_id, question, answer, reading, context, weight, examples):
    card_id = db.card.insert(
        lesson_id=lesson_id,
        user_id=auth.user.id,
        question=question,
        answer=answer,
        reading=reading,
        context=context,
        weight=weight,
        examples=examples
    )
    return int(card_id)

Alexei Vinidiktov

unread,
Dec 6, 2024, 10:13:01 AM12/6/24
to web2py-users
Massimo, if you need any additional information from me, please let me know.

I will really appreciate your answer.

lcham...@gmail.com

unread,
Dec 7, 2024, 7:08:35 PM12/7/24
to web2py-users

I've just come from web2py and I find the py4web doc very incomplete, even for trivial things like:

if you create an application from scaffold, well, you have a set of files and you have to write your functions in controllers.py, but you don't know why. If you try to create (as in web2py) a toto.py, well, py4web never finds it. If you want to take code from examples, well, how do you do it? .... etc.

Massimo Di Pierro

unread,
Dec 7, 2024, 9:52:34 PM12/7/24
to web2py-users
responded in the other thread by I recommend asking those questions here https://groups.google.com/g/py4web
Reply all
Reply to author
Forward
0 new messages