Switch to an event allowlist for watchdog
Ignores the new closed_no_write event type fired by watchdog 5.x that is causing unnecessary reloads.
To prevent such cases in the future, I introduced an event allow list.
fixes https://github.com/pallets/werkzeug/issues/2945
- Test case added
- Change log added
Can we please get a little speed on this one?
werkzeug is currently broken when using it with django-extensions and not pinning watchdog to a 4.x release.
https://github.com/pallets/werkzeug/issues/2945#issuecomment-2354842482
I had to rebase to change the target from main to stable. Since you opened this PR from your main branch, you'll need to reset it: git fetch upstream && git reset --hard upstream/main. Remember to create pull requests from dedicated branches.