diff --git a/reflex/utils/pyi_generator.py b/reflex/utils/pyi_generator.py index 3560b5edb16..cd744860fb6 100644 --- a/reflex/utils/pyi_generator.py +++ b/reflex/utils/pyi_generator.py @@ -1264,7 +1264,7 @@ def scan_all( dict( zip( [ - str(f.relative_to(pyi_hashes_file.parent)) + f.relative_to(pyi_hashes_file.parent).as_posix() for f in file_paths ], hashes, @@ -1291,9 +1291,10 @@ def scan_all( for file_path, hashed_content in zip( file_paths, hashes, strict=False ): - pyi_hashes[str(file_path.relative_to(pyi_hashes_parent))] = ( - hashed_content - ) + formatted_path = file_path.relative_to( + pyi_hashes_parent + ).as_posix() + pyi_hashes[formatted_path] = hashed_content pyi_hashes_file.write_text( json.dumps(pyi_hashes, indent=2, sort_keys=True) + "\n"