-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
Describe the bug
Running bench update --reset --no-backup fails during the supervisor reload step.
The failure occurs when bench attempts to restart the erp-workers supervisor group, which does not exist on this system. This results in ERROR (no such file) for all worker processes and causes the entire update command to exit with a non-zero status.
This happens even though:
- App updates
- Migrations
- Asset builds
all complete successfully.
To Reproduce
Steps to reproduce the behavior:
-
Use a bench setup without ERPNext (Frappe only).
-
Switch Frappe branch from
developtoversion-16:bench switch-branch version-16 --update
-
Run:
bench update --reset --no-backup
-
Observe failure during supervisor reload.
Expected behavior
bench update should:
- Skip restarting supervisor groups that do not exist, or
- Treat missing supervisor groups as a warning instead of a fatal error.
The update process should complete successfully if core steps (migrate, build assets, etc.) succeed.
Actual behavior
The update fails with the following error:
erp-workers:erp-frappe-schedule: ERROR (no such file)
erp-workers:erp-frappe-short-worker-0: ERROR (no such file)
erp-workers:erp-frappe-long-worker-0: ERROR (no such file)
bench.exceptions.CommandFailedError: sudo supervisorctl restart erp-workers:
OS
- Linux: Debian GNU/Linux 12 (bookworm)
Version Information
-
Bench Version: 5.29.0
-
Bench Branch: PyPI (latest)
-
Frappe Version: v16.1.1
-
ERPNext Version: N/A
-
Custom Apps:
eef
Additional context
- This bench setup does not include ERPNext.
- Supervisor web processes (
erp-web) restart successfully. - The
erp-workerssupervisor group does not exist on this system. - No manual modifications were made to supervisor configuration.
- The issue appeared after switching the Frappe branch from
developtoversion-16.
Possible solution
- Check for the existence of a supervisor group before attempting to restart it.
- Handle missing supervisor groups gracefully (warning instead of error).
- Make supervisor restart failures non-fatal during
bench update.