Skip to content

Commit 240ac2b

Browse files
committed
chore: Update version to 0.10.7.2; refactor filesystem sync handling in pipeline classes
1 parent 43ca285 commit 240ac2b

File tree

5 files changed

+9
-9
lines changed

5 files changed

+9
-9
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description = "A simple workflow framework. Hamilton + APScheduler = FlowerPower
44
authors = [{ name = "Volker L.", email = "[email protected]" }]
55
readme = "README.md"
66
requires-python = ">= 3.11"
7-
version = "0.10.7.1"
7+
version = "0.10.7.2"
88
keywords = [
99
"hamilton",
1010
"workflow",

src/flowerpower/pipeline/base.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -80,9 +80,10 @@ def _add_modules_path(self):
8080
None
8181
"""
8282
if self._fs.is_cache_fs:
83-
self._fs.sync()
84-
85-
modules_path = posixpath.join(self._fs.path, self._pipelines_dir)
83+
self._fs.sync_cache()
84+
modules_path = posixpath.join(self._fs.mapper.directory, self._fs.cache_path, self._pipelines_dir)
85+
else:
86+
modules_path = posixpath.join(self._fs.path, self._pipelines_dir)
8687
if modules_path not in sys.path:
8788
sys.path.insert(0, modules_path)
8889

src/flowerpower/pipeline/manager.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,8 +136,7 @@ def __init__(
136136
if not fs:
137137
fs = get_filesystem(self._base_dir, storage_options=storage_options, cached=cached, cache_storage=cache_storage)
138138
self._fs = fs
139-
if cached:
140-
self._fs.sync()
139+
141140

142141
# Store overrides for ProjectConfig loading
143142
self._cfg_dir = cfg_dir or settings.CONFIG_DIR

src/flowerpower/pipeline/registry.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,8 +190,8 @@ def delete(self, name: str, cfg: bool = True, module: bool = False):
190190
)
191191

192192
# Sync filesystem if needed (using _fs)
193-
if hasattr(self._fs, "sync") and callable(getattr(self._fs, "sync")):
194-
self._fs.sync()
193+
if hasattr(self._fs, "sync_cache") and callable(getattr(self._fs, "sync_cache")):
194+
self._fs.sync_cache()
195195

196196
def _get_files(self) -> list[str]:
197197
"""

uv.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)