After migrating an Odoo database from 18.0 to 19.0 using OpenUpgrade, clicking on an employee triggers the org chart endpoint and produces:
AttributeError: 'bool' object has no attribute 'timestamp'
The error is in odoo/addons/hr_org_chart/controllers/hr_org_chart.py:35:
python
write_date=int(employee.write_date.timestamp()) * 1000,
When employee.write_date is False (NULL in DB), .timestamp() fails. This is likely to affect migrated databases where some employee records may have empty write_date.
Workaround applied during migration: patch the controller to check for falsy write_date:
python
write_date=int(employee.write_date.timestamp() * 1000) if employee.write_date else 0,
Description: