invert logic of default hot reload exclusion (#4807)

* invert logic of default hot reload exclusion

* console debug reload paths
This commit is contained in:
Khaleel Al-Adhami 2025-02-11 17:47:44 -08:00 committed by GitHub
parent 6cbdd00169
commit cb2e7df96a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -278,7 +278,7 @@ def get_reload_paths() -> Sequence[Path]:
if path.name.startswith("__"):
# ignore things like __pycache__
return True
return path.name not in (".gitignore", "uploaded_files")
return path.name in (".gitignore", "uploaded_files")
reload_paths = (
tuple(
@ -297,6 +297,8 @@ def get_reload_paths() -> Sequence[Path]:
if all(not path.samefile(exclude) for exclude in exclude_dirs)
)
console.debug(f"Reload paths: {list(map(str, reload_paths))}")
return reload_paths