Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] package/python-web2py: bump to version 3.3.3
@ 2026-10-30 11:53 Angelo Compagnucci
  2026-10-30 20:26 ` Julien Olivain via buildroot
  2026-10-31 14:36 ` [Buildroot] [PATCH v2 0/2] " Angelo Compagnucci
  0 siblings, 2 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-10-30 11:53 UTC (permalink / raw)
  To: buildroot; +Cc: Angelo Compagnucci

Release notes:
https://github.com/web2py/web2py/releases/tag/v3.3.3

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
 package/python-web2py/python-web2py.hash | 2 +-
 package/python-web2py/python-web2py.mk   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/package/python-web2py/python-web2py.hash b/package/python-web2py/python-web2py.hash
index b100a1fec8..fd16d50cc9 100644
--- a/package/python-web2py/python-web2py.hash
+++ b/package/python-web2py/python-web2py.hash
@@ -1,3 +1,3 @@
 # sha256 locally computed
-sha256  b22b5c2db862cdef9e0feace1c8841741a14eb5e735b674d6ce2bd5c7f4cac64  python-web2py-v3.1.1-git4.tar.gz
+sha256  68efbfdc26a1b5a2d20bbfec9de522e7fb88d36b73ab7dac24011ae3d51b3380  python-web2py-v3.3.3-git4.tar.gz
 sha256  2aae96826184a492bc799add49aed7b29036e7aba2d2294fb65053bd30fe55fe  LICENSE.web2py.txt
diff --git a/package/python-web2py/python-web2py.mk b/package/python-web2py/python-web2py.mk
index 68847a2385..27777e3430 100644
--- a/package/python-web2py/python-web2py.mk
+++ b/package/python-web2py/python-web2py.mk
@@ -4,7 +4,7 @@
 #
 ################################################################################
 
-PYTHON_WEB2PY_VERSION_UPSTREAM = 3.1.1
+PYTHON_WEB2PY_VERSION_UPSTREAM = 3.3.3
 PYTHON_WEB2PY_VERSION = v$(PYTHON_WEB2PY_VERSION_UPSTREAM)
 PYTHON_WEB2PY_SITE = https://github.com/web2py/web2py.git
 PYTHON_WEB2PY_SITE_METHOD = git
-- 
2.34.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [Buildroot] [PATCH] package/python-web2py: bump to version 3.3.3
  2026-10-30 11:53 [Buildroot] [PATCH] package/python-web2py: bump to version 3.3.3 Angelo Compagnucci
@ 2026-10-30 20:26 ` Julien Olivain via buildroot
  2026-10-31 14:36 ` [Buildroot] [PATCH v2 0/2] " Angelo Compagnucci
  1 sibling, 0 replies; 11+ messages in thread
From: Julien Olivain via buildroot @ 2026-10-30 20:26 UTC (permalink / raw)
  To: Angelo Compagnucci; +Cc: buildroot

Hi Angelo,

Thanks for the patch.

On 30/10/2026 12:53, Angelo Compagnucci wrote:
> Release notes:
> https://github.com/web2py/web2py/releases/tag/v3.3.3

This release note link does not provide much useful information.
Could you change it to an actual change description, please?

If there is no change summary, you can put for example:
https://github.com/web2py/web2py/compare/v3.1.1...v3.3.3

> 
> Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
> ---
>  package/python-web2py/python-web2py.hash | 2 +-
>  package/python-web2py/python-web2py.mk   | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/package/python-web2py/python-web2py.hash 
> b/package/python-web2py/python-web2py.hash
> index b100a1fec8..fd16d50cc9 100644
> --- a/package/python-web2py/python-web2py.hash
> +++ b/package/python-web2py/python-web2py.hash
> @@ -1,3 +1,3 @@
>  # sha256 locally computed
> -sha256  
> b22b5c2db862cdef9e0feace1c8841741a14eb5e735b674d6ce2bd5c7f4cac64  
> python-web2py-v3.1.1-git4.tar.gz
> +sha256  
> 68efbfdc26a1b5a2d20bbfec9de522e7fb88d36b73ab7dac24011ae3d51b3380  
> python-web2py-v3.3.3-git4.tar.gz

When I tried to download the archive, it failed with the error:

ERROR: while checking hashes from 
package/python-web2py/python-web2py.hash
ERROR: python-web2py-v3.3.3-git4.tar.gz has wrong sha256 hash:
ERROR: expected: 
68efbfdc26a1b5a2d20bbfec9de522e7fb88d36b73ab7dac24011ae3d51b3380
ERROR: got     : 
ecd2e9a0728cd469a2e24a6e5896a0b610318c22c2d28f82bb9d68de551ff856
ERROR: Incomplete download, or man-in-the-middle (MITM) attack

Could you check where this difference is coming from?
Then, fix the hash, please?

Even when fixing the source hash, the build is then
failing with the error:

AttributeError: module 'hashlib' has no attribute 'pbkdf2_hmac'

Could you have a look, please?

>  sha256  
> 2aae96826184a492bc799add49aed7b29036e7aba2d2294fb65053bd30fe55fe  
> LICENSE.web2py.txt
> diff --git a/package/python-web2py/python-web2py.mk 
> b/package/python-web2py/python-web2py.mk
> index 68847a2385..27777e3430 100644
> --- a/package/python-web2py/python-web2py.mk
> +++ b/package/python-web2py/python-web2py.mk
> @@ -4,7 +4,7 @@
>  #
>  
> ################################################################################
> 
> -PYTHON_WEB2PY_VERSION_UPSTREAM = 3.1.1
> +PYTHON_WEB2PY_VERSION_UPSTREAM = 3.3.3
>  PYTHON_WEB2PY_VERSION = v$(PYTHON_WEB2PY_VERSION_UPSTREAM)
>  PYTHON_WEB2PY_SITE = https://github.com/web2py/web2py.git
>  PYTHON_WEB2PY_SITE_METHOD = git
> --
> 2.34.1

Could you send an updated patch addressing those comments, please?

Best regards,

Julien.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v2 0/2] package/python-web2py: bump to version 3.3.3
  2026-10-30 11:53 [Buildroot] [PATCH] package/python-web2py: bump to version 3.3.3 Angelo Compagnucci
  2026-10-30 20:26 ` Julien Olivain via buildroot
@ 2026-10-31 14:36 ` Angelo Compagnucci
  2026-10-31 14:36   ` [Buildroot] [PATCH v2 1/2] package/python-rocket3: new package Angelo Compagnucci
                     ` (2 more replies)
  1 sibling, 3 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-10-31 14:36 UTC (permalink / raw)
  To: buildroot; +Cc: Angelo Compagnucci

web2py 3.3.3 stores binaries/*.zip with Git LFS, so the archive
generated by the git download method depends on git-lfs being installed
on the build host. This is why the hash didn't match for Julien: without
git-lfs the archive contains the LFS pointers (68efbfdc...), with it the
actual zip files.

v2 downloads the release tag archive with the github helper, which is
the same on every host, and uses the python-pydal, python-yatl and new
python-rocket3 packages instead of the git submodules, which are not
part of that archive.

About the "module 'hashlib' has no attribute 'pbkdf2_hmac'" failure: I
couldn't reproduce it with a clean build, with the admin panel enabled
(the default), which selects BR2_PACKAGE_HOST_PYTHON3_SSL. It may come
from a host-python3 built before python-web2py was enabled, as changing
that option doesn't rebuild host-python3.

Changes v1 -> v2:
  - use the comparison between the tags as changelog [Julien]
  - download the release tag archive and add the python-rocket3
    package, as the git archive hash depended on git-lfs [Julien]
  - update the list of files not installed on the target

Angelo Compagnucci (2):
  package/python-rocket3: new package
  package/python-web2py: bump to version 3.3.3

 DEVELOPERS                                 |  1 +
 package/Config.in                          |  1 +
 package/python-rocket3/Config.in           |  8 +++++
 package/python-rocket3/python-rocket3.hash |  5 +++
 package/python-rocket3/python-rocket3.mk   | 15 ++++++++
 package/python-web2py/Config.in            |  1 +
 package/python-web2py/python-web2py.hash   |  2 +-
 package/python-web2py/python-web2py.mk     | 40 ++++++++++++++++------
 8 files changed, 61 insertions(+), 12 deletions(-)
 create mode 100644 package/python-rocket3/Config.in
 create mode 100644 package/python-rocket3/python-rocket3.hash
 create mode 100644 package/python-rocket3/python-rocket3.mk

-- 
2.34.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v2 1/2] package/python-rocket3: new package
  2026-10-31 14:36 ` [Buildroot] [PATCH v2 0/2] " Angelo Compagnucci
@ 2026-10-31 14:36   ` Angelo Compagnucci
  2026-10-31 14:36   ` [Buildroot] [PATCH v2 2/2] package/python-web2py: bump to version 3.3.3 Angelo Compagnucci
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
  2 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-10-31 14:36 UTC (permalink / raw)
  To: buildroot; +Cc: Angelo Compagnucci

rocket3 is a multi-threaded WSGI web server, used by web2py, which
bundles it as a git submodule.

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v1 -> v2:
  - new patch
---
 DEVELOPERS                                 |  1 +
 package/Config.in                          |  1 +
 package/python-rocket3/Config.in           |  8 ++++++++
 package/python-rocket3/python-rocket3.hash |  5 +++++
 package/python-rocket3/python-rocket3.mk   | 15 +++++++++++++++
 5 files changed, 30 insertions(+)
 create mode 100644 package/python-rocket3/Config.in
 create mode 100644 package/python-rocket3/python-rocket3.hash
 create mode 100644 package/python-rocket3/python-rocket3.mk

diff --git a/DEVELOPERS b/DEVELOPERS
index 02834f1438..a4f7df7d6e 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -249,6 +249,7 @@ F:	package/python-can/
 F:	package/python-minimalmodbus/
 F:	package/python-pillow/
 F:	package/python-pydal/
+F:	package/python-rocket3/
 F:	package/python-spidev/
 F:	package/python-web2py/
 F:	package/qpdf/
diff --git a/package/Config.in b/package/Config.in
index 933b072ae0..e4b92fe5a4 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1406,6 +1406,7 @@ menu "External python modules"
 	source "package/python-rfc3987/Config.in"
 	source "package/python-rgbmatrix/Config.in"
 	source "package/python-rich/Config.in"
+	source "package/python-rocket3/Config.in"
 	source "package/python-rpds-py/Config.in"
 	source "package/python-rpi-gpio/Config.in"
 	source "package/python-rpi-ws281x/Config.in"
diff --git a/package/python-rocket3/Config.in b/package/python-rocket3/Config.in
new file mode 100644
index 0000000000..5e7a636613
--- /dev/null
+++ b/package/python-rocket3/Config.in
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_PYTHON_ROCKET3
+	bool "python-rocket3"
+	select BR2_PACKAGE_PYTHON3_SSL # runtime
+	help
+	  A multi-threaded WSGI compliant and secure web server, used
+	  by web2py.
+
+	  https://github.com/web2py/rocket3
diff --git a/package/python-rocket3/python-rocket3.hash b/package/python-rocket3/python-rocket3.hash
new file mode 100644
index 0000000000..b00553fcdb
--- /dev/null
+++ b/package/python-rocket3/python-rocket3.hash
@@ -0,0 +1,5 @@
+# md5, sha256 from https://pypi.org/pypi/rocket3/json
+md5  4bd413cb4a6ca32fc4d27046fda804da  rocket3-20260526.0.tar.gz
+sha256  5828422badec10e45bf18f837f14d3022c98b19ac66dbb8fbaafdb17f8d4cdb3  rocket3-20260526.0.tar.gz
+# Locally computed sha256 checksums
+sha256  1f711e93f1e0c2eec576e2e60597dc2ed6f0a661e4749c6b8a39f0d4a72be468  LICENSE.txt
diff --git a/package/python-rocket3/python-rocket3.mk b/package/python-rocket3/python-rocket3.mk
new file mode 100644
index 0000000000..00e1f07ed6
--- /dev/null
+++ b/package/python-rocket3/python-rocket3.mk
@@ -0,0 +1,15 @@
+################################################################################
+#
+# python-rocket3
+#
+################################################################################
+
+PYTHON_ROCKET3_VERSION = 20260526.0
+PYTHON_ROCKET3_SOURCE = rocket3-$(PYTHON_ROCKET3_VERSION).tar.gz
+PYTHON_ROCKET3_SITE = https://files.pythonhosted.org/packages/ca/f7/fed13d11a5c93e19daddf1fa73ce09fcdb58b43ce2ae95a653150dd3bcca
+PYTHON_ROCKET3_SETUP_TYPE = setuptools
+PYTHON_ROCKET3_LICENSE = BSD-3-Clause
+PYTHON_ROCKET3_LICENSE_FILES = LICENSE.txt
+
+$(eval $(python-package))
+$(eval $(host-python-package))
-- 
2.34.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v2 2/2] package/python-web2py: bump to version 3.3.3
  2026-10-31 14:36 ` [Buildroot] [PATCH v2 0/2] " Angelo Compagnucci
  2026-10-31 14:36   ` [Buildroot] [PATCH v2 1/2] package/python-rocket3: new package Angelo Compagnucci
@ 2026-10-31 14:36   ` Angelo Compagnucci
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
  2 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-10-31 14:36 UTC (permalink / raw)
  To: buildroot; +Cc: Angelo Compagnucci

web2py 3.3.3 stores binaries/*.zip with Git LFS, so the archive
generated from the git repository depends on git-lfs being installed on
the build host: it contains either the zip files or their LFS pointers,
with different hashes.

So download the release tag archive with the github helper instead,
which doesn't include the git submodules (pydal, yatl and rocket3): in
that case, gluon imports the installed modules, provided by
python-pydal, python-yatl and the new python-rocket3 package.
host-python-rocket3 is needed to generate the admin panel password.

Update the list of files not installed on the target, as some of them
were renamed, removed or added in the new version, and also exclude the
Buildroot stamp and file list files.

Changes:
https://github.com/web2py/web2py/compare/v3.1.1...v3.3.3

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v1 -> v2:
  - use the comparison between the tags as changelog [Julien]
  - download the release tag archive with the github helper and use the
    python-pydal, python-yatl and new python-rocket3 packages instead of
    the git submodules, as the git archive hash depended on git-lfs
    being installed [Julien]
  - update the list of files not installed on the target
---
 package/python-web2py/Config.in          |  1 +
 package/python-web2py/python-web2py.hash |  2 +-
 package/python-web2py/python-web2py.mk   | 40 +++++++++++++++++-------
 3 files changed, 31 insertions(+), 12 deletions(-)

diff --git a/package/python-web2py/Config.in b/package/python-web2py/Config.in
index 0c141d9fc5..83ce4b3e74 100644
--- a/package/python-web2py/Config.in
+++ b/package/python-web2py/Config.in
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_PYTHON_WEB2PY
 	bool "python-web2py"
 	select BR2_PACKAGE_PYTHON_PYDAL # runtime
+	select BR2_PACKAGE_PYTHON_ROCKET3 # runtime
 	select BR2_PACKAGE_PYTHON3_ZLIB # runtime
 	select BR2_PACKAGE_PYTHON3_PYEXPAT # runtime
 	select BR2_PACKAGE_PYTHON3_SQLITE # runtime
diff --git a/package/python-web2py/python-web2py.hash b/package/python-web2py/python-web2py.hash
index b100a1fec8..5e7fd0d9b4 100644
--- a/package/python-web2py/python-web2py.hash
+++ b/package/python-web2py/python-web2py.hash
@@ -1,3 +1,3 @@
 # sha256 locally computed
-sha256  b22b5c2db862cdef9e0feace1c8841741a14eb5e735b674d6ce2bd5c7f4cac64  python-web2py-v3.1.1-git4.tar.gz
+sha256  38655b8f1c9737348b61669ccb2beaecdba1f6bf1e9a5cfa697a14b660b31a78  python-web2py-v3.3.3.tar.gz
 sha256  2aae96826184a492bc799add49aed7b29036e7aba2d2294fb65053bd30fe55fe  LICENSE.web2py.txt
diff --git a/package/python-web2py/python-web2py.mk b/package/python-web2py/python-web2py.mk
index 68847a2385..168c1d3445 100644
--- a/package/python-web2py/python-web2py.mk
+++ b/package/python-web2py/python-web2py.mk
@@ -4,11 +4,9 @@
 #
 ################################################################################
 
-PYTHON_WEB2PY_VERSION_UPSTREAM = 3.1.1
+PYTHON_WEB2PY_VERSION_UPSTREAM = 3.3.3
 PYTHON_WEB2PY_VERSION = v$(PYTHON_WEB2PY_VERSION_UPSTREAM)
-PYTHON_WEB2PY_SITE = https://github.com/web2py/web2py.git
-PYTHON_WEB2PY_SITE_METHOD = git
-PYTHON_WEB2PY_GIT_SUBMODULES = YES
+PYTHON_WEB2PY_SITE = $(call github,web2py,web2py,$(PYTHON_WEB2PY_VERSION))
 PYTHON_WEB2PY_LICENSE = LGPL-3.0
 PYTHON_WEB2PY_LICENSE_FILES = LICENSE.web2py.txt
 PYTHON_WEB2PY_CPE_ID_VENDOR = web2py
@@ -21,20 +19,33 @@ PYTHON_WEB2PY_EXCLUSIONS = \
 	welcome.w2p \
 	applications/examples \
 	applications/welcome \
+	binaries \
 	deposit \
+	docker \
 	docs \
 	examples \
 	extras \
 	handlers \
 	scripts \
-	ABOUT \
+	.codecov.yml \
+	.gitattributes \
+	.github \
+	.gitignore \
+	.gitmodules \
+	.travis.yml \
+	ABOUT.web2py.txt \
 	anyserver.py \
-	CHANGELOG \
+	app.yaml \
+	appveyor.yml \
+	CHANGELOG.md \
+	gae.nix \
 	Makefile \
-	MANIFEST.in \
-	README.markdown \
-	setup.py \
-	tox.ini
+	README.md \
+	requirements.gae.txt \
+	requirements.txt \
+	SECURITY.md \
+	tox.ini \
+	versioning-and-support-policy.md
 
 define PYTHON_WEB2PY_GENERATE_PASSWORD
 	$(HOST_DIR)/bin/python -c 'import os; \
@@ -44,15 +55,22 @@ define PYTHON_WEB2PY_GENERATE_PASSWORD
 endef
 
 ifeq ($(BR2_PACKAGE_PYTHON_WEB2PY_INSTALL_ADMIN),y)
+# gluon imports rocket3 to generate the password
+PYTHON_WEB2PY_DEPENDENCIES += host-python-rocket3
 PYTHON_WEB2PY_POST_BUILD_HOOKS += PYTHON_WEB2PY_GENERATE_PASSWORD
 else
 PYTHON_WEB2PY_EXCLUSIONS += applications/admin
 endif
 
+# The build directory also contains the Buildroot stamp and file list
+# files, which must not be installed.
 define PYTHON_WEB2PY_INSTALL_TARGET_CMDS
 	mkdir -p $(TARGET_DIR)/var/www/web2py
 	rsync -a $(@D)/ $(TARGET_DIR)/var/www/web2py/ \
-		$(addprefix --exclude=,$(PYTHON_WEB2PY_EXCLUSIONS))
+		$(addprefix --exclude=,$(PYTHON_WEB2PY_EXCLUSIONS)) \
+		--exclude='.stamp_*' \
+		--exclude='.files-list*' \
+		--exclude=.applied_patches_list
 endef
 
 define PYTHON_WEB2PY_INSTALL_INIT_SYSV
-- 
2.34.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot
  2026-10-31 14:36 ` [Buildroot] [PATCH v2 0/2] " Angelo Compagnucci
  2026-10-31 14:36   ` [Buildroot] [PATCH v2 1/2] package/python-rocket3: new package Angelo Compagnucci
  2026-10-31 14:36   ` [Buildroot] [PATCH v2 2/2] package/python-web2py: bump to version 3.3.3 Angelo Compagnucci
@ 2026-11-19  9:56   ` Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 2/6] package/python-rocket3: new package Angelo Compagnucci
                       ` (4 more replies)
  2 siblings, 5 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-11-19  9:56 UTC (permalink / raw)
  To: buildroot
  Cc: Angelo Compagnucci, Julien Olivain, Thomas Petazzoni,
	James Hilliard, Fiona Klute

S51web2py starts web2py with -a '"<recycle>"'. The single quotes keep
the double quotes, so web2py gets "<recycle>" with the quotes, and not
the <recycle> keyword, which keeps the current password. web2py then
takes "<recycle>" as the new admin password, and overwrites the one set
at build time by BR2_PACKAGE_PYTHON_WEB2PY_PASSWORD.

Drop the double quotes. The systemd unit is right: it passes
-a '<recycle>', and systemd removes the single quotes.

The bug is there since the package was added, in commit 7c0fab65aa
("package/python-web2py: new package").

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v2 -> v3:
  - new patch: the new runtime test found this bug

 package/python-web2py/S51web2py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/package/python-web2py/S51web2py b/package/python-web2py/S51web2py
index 8d229e16cf..11fe912afb 100644
--- a/package/python-web2py/S51web2py
+++ b/package/python-web2py/S51web2py
@@ -6,7 +6,7 @@ case "$1" in
 		start-stop-daemon -S -q -m -p /run/web2py.pid \
 			-c www-data \
 			-b -x /var/www/web2py/web2py.py \
-			-- --nogui -a '"<recycle>"' -i 0.0.0.0 -p 8000
+			-- --nogui -a '<recycle>' -i 0.0.0.0 -p 8000
 		[ $? = 0 ] && echo "OK" || echo "FAIL"
 		;;
 	stop)
-- 
2.53.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v3 2/6] package/python-rocket3: new package
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
@ 2026-11-19  9:56     ` Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 3/6] package/python-pydal: bump to version 20261107.0 Angelo Compagnucci
                       ` (3 subsequent siblings)
  4 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-11-19  9:56 UTC (permalink / raw)
  To: buildroot
  Cc: Angelo Compagnucci, Julien Olivain, Thomas Petazzoni,
	James Hilliard, Fiona Klute

rocket3 is a multi-threaded WSGI web server, used by web2py, which
bundles it as a git submodule.

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v2 -> v3:
  - none

Changes v1 -> v2:
  - new patch

 DEVELOPERS                                 |  1 +
 package/Config.in                          |  1 +
 package/python-rocket3/Config.in           |  8 ++++++++
 package/python-rocket3/python-rocket3.hash |  5 +++++
 package/python-rocket3/python-rocket3.mk   | 15 +++++++++++++++
 5 files changed, 30 insertions(+)
 create mode 100644 package/python-rocket3/Config.in
 create mode 100644 package/python-rocket3/python-rocket3.hash
 create mode 100644 package/python-rocket3/python-rocket3.mk

diff --git a/DEVELOPERS b/DEVELOPERS
index 1d2960f9b3..e4c7e494cd 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -251,6 +251,7 @@ F:	package/python-can/
 F:	package/python-minimalmodbus/
 F:	package/python-pillow/
 F:	package/python-pydal/
+F:	package/python-rocket3/
 F:	package/python-spidev/
 F:	package/python-web2py/
 F:	package/qpdf/
diff --git a/package/Config.in b/package/Config.in
index a24c73c2ca..4e022d24fd 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1406,6 +1406,7 @@ menu "External python modules"
 	source "package/python-rfc3987/Config.in"
 	source "package/python-rgbmatrix/Config.in"
 	source "package/python-rich/Config.in"
+	source "package/python-rocket3/Config.in"
 	source "package/python-rpds-py/Config.in"
 	source "package/python-rpi-gpio/Config.in"
 	source "package/python-rpi-ws281x/Config.in"
diff --git a/package/python-rocket3/Config.in b/package/python-rocket3/Config.in
new file mode 100644
index 0000000000..5e7a636613
--- /dev/null
+++ b/package/python-rocket3/Config.in
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_PYTHON_ROCKET3
+	bool "python-rocket3"
+	select BR2_PACKAGE_PYTHON3_SSL # runtime
+	help
+	  A multi-threaded WSGI compliant and secure web server, used
+	  by web2py.
+
+	  https://github.com/web2py/rocket3
diff --git a/package/python-rocket3/python-rocket3.hash b/package/python-rocket3/python-rocket3.hash
new file mode 100644
index 0000000000..b00553fcdb
--- /dev/null
+++ b/package/python-rocket3/python-rocket3.hash
@@ -0,0 +1,5 @@
+# md5, sha256 from https://pypi.org/pypi/rocket3/json
+md5  4bd413cb4a6ca32fc4d27046fda804da  rocket3-20260526.0.tar.gz
+sha256  5828422badec10e45bf18f837f14d3022c98b19ac66dbb8fbaafdb17f8d4cdb3  rocket3-20260526.0.tar.gz
+# Locally computed sha256 checksums
+sha256  1f711e93f1e0c2eec576e2e60597dc2ed6f0a661e4749c6b8a39f0d4a72be468  LICENSE.txt
diff --git a/package/python-rocket3/python-rocket3.mk b/package/python-rocket3/python-rocket3.mk
new file mode 100644
index 0000000000..00e1f07ed6
--- /dev/null
+++ b/package/python-rocket3/python-rocket3.mk
@@ -0,0 +1,15 @@
+################################################################################
+#
+# python-rocket3
+#
+################################################################################
+
+PYTHON_ROCKET3_VERSION = 20260526.0
+PYTHON_ROCKET3_SOURCE = rocket3-$(PYTHON_ROCKET3_VERSION).tar.gz
+PYTHON_ROCKET3_SITE = https://files.pythonhosted.org/packages/ca/f7/fed13d11a5c93e19daddf1fa73ce09fcdb58b43ce2ae95a653150dd3bcca
+PYTHON_ROCKET3_SETUP_TYPE = setuptools
+PYTHON_ROCKET3_LICENSE = BSD-3-Clause
+PYTHON_ROCKET3_LICENSE_FILES = LICENSE.txt
+
+$(eval $(python-package))
+$(eval $(host-python-package))
-- 
2.53.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v3 3/6] package/python-pydal: bump to version 20261107.0
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 2/6] package/python-rocket3: new package Angelo Compagnucci
@ 2026-11-19  9:56     ` Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 4/6] package/python-web2py: security bump to version 3.4.1 Angelo Compagnucci
                       ` (2 subsequent siblings)
  4 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-11-19  9:56 UTC (permalink / raw)
  To: buildroot
  Cc: Angelo Compagnucci, Julien Olivain, Thomas Petazzoni,
	James Hilliard, Fiona Klute

pyDAL does not publish release notes. This version reworks the
internals: pydal.adapters, pydal.dialects, pydal.parsers and
pydal.representers are replaced by pydal.backends, pydal.compilers and
pydal.backend_base. Code that imports the old modules breaks.

python-web2py 3.1.1 is not affected: it uses its own copy of pydal,
from its git submodule. The next patch bumps python-web2py to 3.4.1,
which uses the installed pydal and needs this version.

The pydal runtime test now takes about 8 seconds on the emulated ARM926
to import pydal and run its sample, more than the default timeout of 5
seconds: set its timeout to 30 seconds.

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v2 -> v3:
  - new patch: python-web2py 3.4.1 needs it

 package/python-pydal/python-pydal.hash             | 4 ++--
 package/python-pydal/python-pydal.mk               | 4 ++--
 support/testing/tests/package/test_python_pydal.py | 1 +
 3 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/package/python-pydal/python-pydal.hash b/package/python-pydal/python-pydal.hash
index 22d0114dec..5aa2279597 100644
--- a/package/python-pydal/python-pydal.hash
+++ b/package/python-pydal/python-pydal.hash
@@ -1,5 +1,5 @@
 # md5, sha256 from https://pypi.org/pypi/pydal/json
-md5  21ca33debbc8a022137143d4b04dbaa4  pydal-20260520.0.tar.gz
-sha256  a1a01d28655231b7e0893ca13e9c92084549f7761042e1ae9ef70d37146737c4  pydal-20260520.0.tar.gz
+md5  75a3be58cd1337e95225845ac7e42d21  pydal-20261107.0.tar.gz
+sha256  db02ac001d3cd1dbd4eb40d4267aa4523f60b450572c3574a3f586712489e663  pydal-20261107.0.tar.gz
 # Locally computed sha256 checksums
 sha256  1f711e93f1e0c2eec576e2e60597dc2ed6f0a661e4749c6b8a39f0d4a72be468  LICENSE.txt
diff --git a/package/python-pydal/python-pydal.mk b/package/python-pydal/python-pydal.mk
index 45ccb2e888..ccfadc75f5 100644
--- a/package/python-pydal/python-pydal.mk
+++ b/package/python-pydal/python-pydal.mk
@@ -4,9 +4,9 @@
 #
 ################################################################################
 
-PYTHON_PYDAL_VERSION = 20260520.0
+PYTHON_PYDAL_VERSION = 20261107.0
 PYTHON_PYDAL_SOURCE = pydal-$(PYTHON_PYDAL_VERSION).tar.gz
-PYTHON_PYDAL_SITE = https://files.pythonhosted.org/packages/20/4e/1d576fcb6857f56cd0aeb413c387044fd609140628d1c401b7ae29ee6190
+PYTHON_PYDAL_SITE = https://files.pythonhosted.org/packages/00/17/5f6065b22a6a3d4f3b634a77683d7a1b891a927207135e03d5cf8b1e9fd3
 PYTHON_PYDAL_LICENSE = BSD-3-Clause
 PYTHON_PYDAL_LICENSE_FILES = LICENSE.txt
 PYTHON_PYDAL_SETUP_TYPE = setuptools
diff --git a/support/testing/tests/package/test_python_pydal.py b/support/testing/tests/package/test_python_pydal.py
index b0166c7a8a..6a6573eb88 100644
--- a/support/testing/tests/package/test_python_pydal.py
+++ b/support/testing/tests/package/test_python_pydal.py
@@ -10,3 +10,4 @@ class TestPythonPy3PyDAL(TestPythonPackageBase):
         BR2_PACKAGE_PYTHON_PYDAL=y
         """
     sample_scripts = ["tests/package/sample_python_pydal.py"]
+    timeout = 30
-- 
2.53.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v3 4/6] package/python-web2py: security bump to version 3.4.1
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 2/6] package/python-rocket3: new package Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 3/6] package/python-pydal: bump to version 20261107.0 Angelo Compagnucci
@ 2026-11-19  9:56     ` Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 5/6] package/python-web2py: rework the init script Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 6/6] support/testing: add python-web2py runtime test Angelo Compagnucci
  4 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-11-19  9:56 UTC (permalink / raw)
  To: buildroot
  Cc: Angelo Compagnucci, Julien Olivain, Thomas Petazzoni,
	James Hilliard, Fiona Klute

Fixes the following security issues:

- CVE-2026-79318: directory traversal in read_file() and write_file()
  of the admin webservices
- GHSA-2vvc-854p-r9jv: reflected XSS via the Host header in the admin
  edit view

Upstream also fixed other security issues that have no advisory ID.
Among them:

- code execution through eval() in appadmin
- a flaw in the session_id handling
- an open redirect
- XSS in the XML() sanitizer and in Markmin
- a CSRF bypass in forms
- LDAP injection in the LDAP authentication
- directory traversal when the admin application unpacks an application

web2py 3.4.1 needs pydal 20261107.0, bumped in the previous patch: it
imports pydal.backend_base, which older versions do not have.

web2py stores binaries/*.zip with Git LFS, so the archive generated
from the git repository depends on git-lfs being installed on the build
host: it contains either the zip files or their LFS pointers, with
different hashes.

So download the release tag archive with the github helper instead,
which doesn't include the git submodules (pydal, yatl and rocket3): in
that case, gluon imports the installed modules, provided by
python-pydal, python-yatl and the new python-rocket3 package.
host-python-rocket3 is needed to generate the admin panel password.

Update the list of files not installed on the target, as some of them
were renamed, removed or added in the new version, and also exclude the
Buildroot stamp and file list files.

Changes:
https://github.com/web2py/web2py/compare/v3.1.1...v3.4.1

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v2 -> v3:
  - bump to 3.4.1 instead of 3.3.3: it fixes several security issues.
    3.4.1 needs pydal 20261107.0, bumped in the new patch 3/6.
  - .travis.yml is gone in 3.4.1: drop it from the files not installed

Changes v1 -> v2:
  - use the comparison between the tags as changelog [Julien Olivain]
  - download the release tag archive with the github helper and use the
    python-pydal, python-yatl and new python-rocket3 packages instead of
    the git submodules, as the git archive hash depended on git-lfs
    being installed [Julien Olivain]
  - update the list of files not installed on the target

 package/python-web2py/Config.in          |  1 +
 package/python-web2py/python-web2py.hash |  2 +-
 package/python-web2py/python-web2py.mk   | 39 +++++++++++++++++-------
 3 files changed, 30 insertions(+), 12 deletions(-)

diff --git a/package/python-web2py/Config.in b/package/python-web2py/Config.in
index 0c141d9fc5..83ce4b3e74 100644
--- a/package/python-web2py/Config.in
+++ b/package/python-web2py/Config.in
@@ -1,6 +1,7 @@
 config BR2_PACKAGE_PYTHON_WEB2PY
 	bool "python-web2py"
 	select BR2_PACKAGE_PYTHON_PYDAL # runtime
+	select BR2_PACKAGE_PYTHON_ROCKET3 # runtime
 	select BR2_PACKAGE_PYTHON3_ZLIB # runtime
 	select BR2_PACKAGE_PYTHON3_PYEXPAT # runtime
 	select BR2_PACKAGE_PYTHON3_SQLITE # runtime
diff --git a/package/python-web2py/python-web2py.hash b/package/python-web2py/python-web2py.hash
index b100a1fec8..0f4f259e61 100644
--- a/package/python-web2py/python-web2py.hash
+++ b/package/python-web2py/python-web2py.hash
@@ -1,3 +1,3 @@
 # sha256 locally computed
-sha256  b22b5c2db862cdef9e0feace1c8841741a14eb5e735b674d6ce2bd5c7f4cac64  python-web2py-v3.1.1-git4.tar.gz
+sha256  3b04f9caf805cdbd46226c1dd7d554fd1ee34d9c3e694813929a9e6335a2595e  python-web2py-v3.4.1.tar.gz
 sha256  2aae96826184a492bc799add49aed7b29036e7aba2d2294fb65053bd30fe55fe  LICENSE.web2py.txt
diff --git a/package/python-web2py/python-web2py.mk b/package/python-web2py/python-web2py.mk
index 68847a2385..53d7572d36 100644
--- a/package/python-web2py/python-web2py.mk
+++ b/package/python-web2py/python-web2py.mk
@@ -4,11 +4,9 @@
 #
 ################################################################################
 
-PYTHON_WEB2PY_VERSION_UPSTREAM = 3.1.1
+PYTHON_WEB2PY_VERSION_UPSTREAM = 3.4.1
 PYTHON_WEB2PY_VERSION = v$(PYTHON_WEB2PY_VERSION_UPSTREAM)
-PYTHON_WEB2PY_SITE = https://github.com/web2py/web2py.git
-PYTHON_WEB2PY_SITE_METHOD = git
-PYTHON_WEB2PY_GIT_SUBMODULES = YES
+PYTHON_WEB2PY_SITE = $(call github,web2py,web2py,$(PYTHON_WEB2PY_VERSION))
 PYTHON_WEB2PY_LICENSE = LGPL-3.0
 PYTHON_WEB2PY_LICENSE_FILES = LICENSE.web2py.txt
 PYTHON_WEB2PY_CPE_ID_VENDOR = web2py
@@ -21,20 +19,32 @@ PYTHON_WEB2PY_EXCLUSIONS = \
 	welcome.w2p \
 	applications/examples \
 	applications/welcome \
+	binaries \
 	deposit \
+	docker \
 	docs \
 	examples \
 	extras \
 	handlers \
 	scripts \
-	ABOUT \
+	.codecov.yml \
+	.gitattributes \
+	.github \
+	.gitignore \
+	.gitmodules \
+	ABOUT.web2py.txt \
 	anyserver.py \
-	CHANGELOG \
+	app.yaml \
+	appveyor.yml \
+	CHANGELOG.md \
+	gae.nix \
 	Makefile \
-	MANIFEST.in \
-	README.markdown \
-	setup.py \
-	tox.ini
+	README.md \
+	requirements.gae.txt \
+	requirements.txt \
+	SECURITY.md \
+	tox.ini \
+	versioning-and-support-policy.md
 
 define PYTHON_WEB2PY_GENERATE_PASSWORD
 	$(HOST_DIR)/bin/python -c 'import os; \
@@ -44,15 +54,22 @@ define PYTHON_WEB2PY_GENERATE_PASSWORD
 endef
 
 ifeq ($(BR2_PACKAGE_PYTHON_WEB2PY_INSTALL_ADMIN),y)
+# gluon imports rocket3 to generate the password
+PYTHON_WEB2PY_DEPENDENCIES += host-python-rocket3
 PYTHON_WEB2PY_POST_BUILD_HOOKS += PYTHON_WEB2PY_GENERATE_PASSWORD
 else
 PYTHON_WEB2PY_EXCLUSIONS += applications/admin
 endif
 
+# The build directory also contains the Buildroot stamp and file list
+# files, which must not be installed.
 define PYTHON_WEB2PY_INSTALL_TARGET_CMDS
 	mkdir -p $(TARGET_DIR)/var/www/web2py
 	rsync -a $(@D)/ $(TARGET_DIR)/var/www/web2py/ \
-		$(addprefix --exclude=,$(PYTHON_WEB2PY_EXCLUSIONS))
+		$(addprefix --exclude=,$(PYTHON_WEB2PY_EXCLUSIONS)) \
+		--exclude='.stamp_*' \
+		--exclude='.files-list*' \
+		--exclude=.applied_patches_list
 endef
 
 define PYTHON_WEB2PY_INSTALL_INIT_SYSV
-- 
2.53.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v3 5/6] package/python-web2py: rework the init script
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
                       ` (2 preceding siblings ...)
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 4/6] package/python-web2py: security bump to version 3.4.1 Angelo Compagnucci
@ 2026-11-19  9:56     ` Angelo Compagnucci
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 6/6] support/testing: add python-web2py runtime test Angelo Compagnucci
  4 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-11-19  9:56 UTC (permalink / raw)
  To: buildroot
  Cc: Angelo Compagnucci, Julien Olivain, Thomas Petazzoni,
	James Hilliard, Fiona Klute

Rework S51web2py on the model of the other init scripts:

- set DAEMON and PIDFILE, and read /etc/default/web2py, which can
  change WEB2PY_ARGS;
- web2py.py is a python script, so the process is python. Start it as
  "/usr/bin/python3 web2py.py", and give the same --exec on stop, so
  that start-stop-daemon finds the process: a second start no longer
  starts a second server, and stop really waits for the process;
- fix the shellcheck warnings, and remove the file from
  .checkpackageignore.

Also use --no_gui instead of --nogui, which web2py 3.4.1 deprecates, in
the init script and in the systemd unit.

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v2 -> v3:
  - new patch

 .checkpackageignore                  |  1 -
 package/python-web2py/S51web2py      | 75 ++++++++++++++++++++--------
 package/python-web2py/web2py.service |  2 +-
 3 files changed, 56 insertions(+), 22 deletions(-)

diff --git a/.checkpackageignore b/.checkpackageignore
index 25c668db54..06f308174e 100644
--- a/.checkpackageignore
+++ b/.checkpackageignore
@@ -738,7 +738,6 @@ package/python-pyzmq/0001-detect.py-fix-the-ZMQ-version-check-to-the-ZMQ-versi.p
 package/python-scipy/0001-build-sh4-FE.patch lib_patch.Upstream
 package/python-setuptools/0001-add-executable.patch lib_patch.Upstream
 package/python-sip/0001-remove-join-from-sip-h-files-string.patch lib_patch.Upstream
-package/python-web2py/S51web2py Shellcheck lib_sysv.Variables
 package/qextserialport/0001-Create-a-main-include-file-QExtSerialPort.patch lib_patch.Upstream
 package/qextserialport/0002-Tell-qmake-to-add-a-pkgconfig-file-to-ease-usage-wit.patch lib_patch.Upstream
 package/qt5/qt5base/0001-qtbase-Fix-build-error-when-using-EGL.patch lib_patch.Upstream
diff --git a/package/python-web2py/S51web2py b/package/python-web2py/S51web2py
index 11fe912afb..f0a16dc23f 100644
--- a/package/python-web2py/S51web2py
+++ b/package/python-web2py/S51web2py
@@ -1,25 +1,60 @@
 #!/bin/sh
 
+DAEMON="web2py"
+PIDFILE="/var/run/$DAEMON.pid"
+
+# "<recycle>" keeps the admin password set at build time.
+WEB2PY_ARGS="--no_gui -a <recycle> -i 0.0.0.0 -p 8000"
+
+# shellcheck source=/dev/null
+[ -r "/etc/default/$DAEMON" ] && . "/etc/default/$DAEMON"
+
+# web2py.py is a python script, so the process to look for is python.
+start() {
+	printf 'Starting %s: ' "$DAEMON"
+	# shellcheck disable=SC2086 # we need the word splitting
+	start-stop-daemon --start --background --make-pidfile \
+		--pidfile "$PIDFILE" --chuid www-data \
+		--exec /usr/bin/python3 -- /var/www/web2py/web2py.py $WEB2PY_ARGS
+	status=$?
+	if [ "$status" -eq 0 ]; then
+		echo "OK"
+	else
+		echo "FAIL"
+	fi
+	return "$status"
+}
+
+stop() {
+	printf 'Stopping %s: ' "$DAEMON"
+	start-stop-daemon --stop --pidfile "$PIDFILE" --exec /usr/bin/python3
+	status=$?
+	if [ "$status" -eq 0 ]; then
+		echo "OK"
+	else
+		echo "FAIL"
+		return "$status"
+	fi
+	while start-stop-daemon --stop --test --quiet --pidfile "$PIDFILE" \
+		--exec /usr/bin/python3; do
+		sleep 0.1
+	done
+	rm -f "$PIDFILE"
+	return "$status"
+}
+
+restart() {
+	stop
+	start
+}
+
 case "$1" in
-	start)
-		printf "Starting web2py: "
-		start-stop-daemon -S -q -m -p /run/web2py.pid \
-			-c www-data \
-			-b -x /var/www/web2py/web2py.py \
-			-- --nogui -a '<recycle>' -i 0.0.0.0 -p 8000
-		[ $? = 0 ] && echo "OK" || echo "FAIL"
-		;;
-	stop)
-		printf "Stopping web2py: "
-		start-stop-daemon -K -q -p /run/web2py.pid
-		[ $? = 0 ] && echo "OK" || echo "FAIL"
-		;;
-	restart)
-		"$0" stop
-		sleep 1
-		"$0" start
-		;;
+	start|stop|restart)
+		"$1";;
+	reload)
+		# Restart, since there is no true "reload" feature.
+		restart;;
 	*)
-		echo "Usage: $0 {start|stop|restart}"
-		;;
+		echo "Usage: $0 {start|stop|restart|reload}"
+		exit 1
 esac
diff --git a/package/python-web2py/web2py.service b/package/python-web2py/web2py.service
index 0274bd8c53..dcf083d3ea 100644
--- a/package/python-web2py/web2py.service
+++ b/package/python-web2py/web2py.service
@@ -4,7 +4,7 @@ After=network.target
 
 [Service]
 Type=simple
-ExecStart=/var/www/web2py/web2py.py --nogui -a '<recycle>' -i 0.0.0.0 -p 8000
+ExecStart=/var/www/web2py/web2py.py --no_gui -a '<recycle>' -i 0.0.0.0 -p 8000
 User=www-data
 
 [Install]
-- 
2.53.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [Buildroot] [PATCH v3 6/6] support/testing: add python-web2py runtime test
  2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
                       ` (3 preceding siblings ...)
  2026-11-19  9:56     ` [Buildroot] [PATCH v3 5/6] package/python-web2py: rework the init script Angelo Compagnucci
@ 2026-11-19  9:56     ` Angelo Compagnucci
  4 siblings, 0 replies; 11+ messages in thread
From: Angelo Compagnucci @ 2026-11-19  9:56 UTC (permalink / raw)
  To: buildroot
  Cc: Angelo Compagnucci, Julien Olivain, Thomas Petazzoni,
	James Hilliard, Fiona Klute

The test boots a system where S51web2py starts web2py, then logs in to
the admin application:

- with a wrong password, which must fail;
- with the password set in the configuration, which must succeed: the
  admin application then redirects to its site page.

This checks the admin password generated at build time.

Then it checks the init script: a second start must find the running
server, and nothing must answer once the service is stopped.

Signed-off-by: Angelo Compagnucci <angelo.compagnucci@gmail.com>
---
Changes v2 -> v3:
  - new patch

 DEVELOPERS                                    |  1 +
 .../tests/package/test_python_web2py.py       | 61 +++++++++++++++++++
 2 files changed, 62 insertions(+)
 create mode 100644 support/testing/tests/package/test_python_web2py.py

diff --git a/DEVELOPERS b/DEVELOPERS
index e4c7e494cd..4e267125b1 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -266,6 +266,7 @@ F:	package/sshguard/
 F:	package/sunwait/
 F:	package/sysdig/
 F:	package/uthash/
+F:	support/testing/tests/package/test_python_web2py.py
 
 N:	Andy Shevchenko <andy.shevchenko@gmail.com>
 F:	package/fb-test-app/
diff --git a/support/testing/tests/package/test_python_web2py.py b/support/testing/tests/package/test_python_web2py.py
new file mode 100644
index 0000000000..f6f65c8cf7
--- /dev/null
+++ b/support/testing/tests/package/test_python_web2py.py
@@ -0,0 +1,61 @@
+import os
+import time
+
+from tests.package.test_python import TestPythonPackageBase
+
+
+class TestPythonPy3Web2py(TestPythonPackageBase):
+    __test__ = True
+    config = TestPythonPackageBase.config + \
+        """
+        BR2_PACKAGE_PYTHON3=y
+        BR2_PACKAGE_PYTHON_WEB2PY=y
+        BR2_PACKAGE_PYTHON_WEB2PY_PASSWORD="buildroot"
+        BR2_TARGET_ROOTFS_EXT2=y
+        BR2_TARGET_ROOTFS_EXT2_SIZE="200M"
+        """
+    timeout = 120
+
+    # The root filesystem is too big for an initramfs
+    def login(self):
+        ext2_file = os.path.join(self.builddir, "images", "rootfs.ext2")
+        self.emulator.boot(arch="armv5",
+                           kernel="builtin",
+                           options=["-drive", "file=%s,if=scsi,format=raw" % ext2_file],
+                           kernel_cmdline=["rootwait", "root=/dev/sda"])
+        self.emulator.login()
+
+    # The admin application redirects to its site page once logged in.
+    def login_admin(self, password):
+        cmd = "wget -S -O /dev/null --post-data 'password=%s' " % password
+        cmd += "http://127.0.0.1:8000/admin/default/index 2>&1"
+        output, _ = self.emulator.run(cmd, timeout=self.timeout)
+        return any("Location: /admin/default/site" in line for line in output)
+
+    def test_run(self):
+        self.login()
+
+        # S51web2py starts web2py at boot: wait for it to answer.
+        for attempt in range(60):
+            cmd = "wget -q -O /dev/null http://127.0.0.1:8000/admin/default/index"
+            _, exit_code = self.emulator.run(cmd, timeout=self.timeout)
+            if exit_code == 0:
+                break
+            time.sleep(2)
+        else:
+            self.fail("Timeout while waiting for web2py")
+
+        self.assertFalse(self.login_admin("wrong"))
+        self.assertTrue(self.login_admin("buildroot"))
+
+        # A second start must find the running server.
+        _, exit_code = self.emulator.run("/etc/init.d/S51web2py start")
+        self.assertNotEqual(exit_code, 0)
+
+        # Stop the service: nothing answers anymore.
+        _, exit_code = self.emulator.run("/etc/init.d/S51web2py stop",
+                                         timeout=self.timeout)
+        self.assertEqual(exit_code, 0)
+        cmd = "wget -q -O /dev/null http://127.0.0.1:8000/admin/default/index"
+        _, exit_code = self.emulator.run(cmd, timeout=self.timeout)
+        self.assertNotEqual(exit_code, 0)
-- 
2.53.0

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-11-19  9:56 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-30 11:53 [Buildroot] [PATCH] package/python-web2py: bump to version 3.3.3 Angelo Compagnucci
2026-10-30 20:26 ` Julien Olivain via buildroot
2026-10-31 14:36 ` [Buildroot] [PATCH v2 0/2] " Angelo Compagnucci
2026-10-31 14:36   ` [Buildroot] [PATCH v2 1/2] package/python-rocket3: new package Angelo Compagnucci
2026-10-31 14:36   ` [Buildroot] [PATCH v2 2/2] package/python-web2py: bump to version 3.3.3 Angelo Compagnucci
2026-11-19  9:56   ` [Buildroot] [PATCH v3 1/6] package/python-web2py: keep the admin password at boot Angelo Compagnucci
2026-11-19  9:56     ` [Buildroot] [PATCH v3 2/6] package/python-rocket3: new package Angelo Compagnucci
2026-11-19  9:56     ` [Buildroot] [PATCH v3 3/6] package/python-pydal: bump to version 20261107.0 Angelo Compagnucci
2026-11-19  9:56     ` [Buildroot] [PATCH v3 4/6] package/python-web2py: security bump to version 3.4.1 Angelo Compagnucci
2026-11-19  9:56     ` [Buildroot] [PATCH v3 5/6] package/python-web2py: rework the init script Angelo Compagnucci
2026-11-19  9:56     ` [Buildroot] [PATCH v3 6/6] support/testing: add python-web2py runtime test Angelo Compagnucci

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox