浏览代码

invert logic of default hot reload exclusion (#4807)

* invert logic of default hot reload exclusion

* console debug reload paths
Khaleel Al-Adhami 3 月之前
父节点
当前提交
cb2e7df96a
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      reflex/utils/exec.py

+ 3 - 1
reflex/utils/exec.py

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