Skip to content

Match nested files in watchmedo patterns with watchdog 7 - #232

Open
itzzdev09 wants to merge 1 commit into
vcon-dev:mainfrom
itzzdev09:fix/watchdog-7-patterns
Open

itzzdev09 wants to merge 1 commit into
vcon-dev:mainfrom
itzzdev09:fix/watchdog-7-patterns

Conversation

@itzzdev09

Copy link
Copy Markdown

watchdog 7 matches patterns with PurePath.full_match() (relative to the watched directory since 7.1.1), so *.py no longer matches files in subdirectories. The conserver would stop restarting when a file in a subdirectory changes. The command in the manual installation guide is updated too. uv.lock pins watchdog 6.0.0 today and the dependency is unbounded, so this applies on upgrade.

Using *.py;**/*.py matches at every depth again and selects the same files as before on watchdog 6, so no version bound is needed.

Checked with a live recursive watch on watchdog 6.0.0, 7.1.0 and 7.1.1: the old patterns miss nested files on 7.x, and the new ones report the same files that the old ones did on 6.0.0. watchmedo shell-command --recursive with *.py and *.py;**/*.py behaved the same way on 6.0.0 and 7.1.1. docker compose config on an equivalent file shows the quoted value reaching watchmedo as one argument. I did not run this repository's dev stack.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant