Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FIX] core: --dev=reload with watchdog==4.0.0
If you're on Linux, make sure `inotify` is uninstalled: pip uninstall inotify Install `watchdog` to its latest release, 4.0.0, and start odoo in dev-reload mode. This mode restart the application everytime a file is modified in one of the addons. pip install watchdog==4.0.0 -U odoo-bin ... --dev=reload # replace ... with your arguments Modify a file, save it. The server doesn't reload while it should. Before gorakhargosh/watchdog@41fca1eb, only the `FileSystemMovedEvent` class had a `dest_path` attribute (actually a property). In our code, we used a `getattr` approach to fallback on `src_path` (which is set on all three event classes) in case `dest_path` was not set. Since that commit, the attribute has been moved to the base abstract class `FileSystemEvent` which all three `FileCreatedEvent`, `FileModifiedEvent`, and `FileMovedEvent` inherit. Hence the attribute is always set (sometime to an empty string) and the getattr must be adapted. The new code supports both watchdog==3.0.0 and watchdog==4.0.0. closes odoo#159045 X-original-commit: 9dd4418 Signed-off-by: Julien Castiaux (juc) <[email protected]>
- Loading branch information