Daily updates from Odoo
Tuesday, September 23, 2025
1 change · saas-17.4
Resolved issues and error corrections
Planning now blocks shift templates that span an excessive number of days before they can be used. This prevents employees from encountering an error when creating shifts from templates and gives users clearer feedback instead.
Original PR description
Currently, An error occurs when the employee adds a working 'Shift' in the resource calendar using a planning template that has too many span days. Step to produce: - Install the `planning` module. - Go to Planning / Configuration / Shift Templates, and Create a template that span day is more than 1000. - Create a 'Shift' in 'My Planning', Add an administrator as 'Resource,' and click on the 'Shift Templates'. `AttributeError: 'bool' object has no attribute 'replace'` The issue occurs because the system attempts to replace an hour and minute with end time at [1], But end time is False(boolean) as the 'plan_days' method returns a False value due to the excessive span days in the template. Link [1]: https://github.com/odoo/enterprise/blob/fd94c8bbe8f75540681f3b85ebf8d9767cf30f2a/planning/models/planning.py#L636 To resolve this, raise a validation error if the user tries to create a shift template with an excessive span days. Sentry-6190026432