Skip to content

Commit 6add0bb

Browse files
committed
fix(win): ensure Scripts/ dir exists before shim detection on Windows
On CI, managed interpreter Scripts/ dirs don't exist yet when _collect_all_dispatcher_bin_dirs() runs, causing the daemon to never spawn. mkdir Scripts/ if missing so shim push works on both fresh CI environments and existing local installs.
1 parent 6f3f836 commit 6add0bb

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/omnipkg/dispatcher.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -324,8 +324,9 @@ def _collect_all_dispatcher_bin_dirs() -> list:
324324
# but shims live in Scripts/ — check both
325325
if sys.platform == "win32":
326326
scripts_dir = adopted_bin / "Scripts"
327-
if scripts_dir.exists():
328-
adopted_bin = scripts_dir
327+
if not scripts_dir.exists():
328+
scripts_dir.mkdir(parents=True, exist_ok=True)
329+
adopted_bin = scripts_dir
329330
if adopted_bin.resolve() != native_bin.resolve() and adopted_bin.exists():
330331
dirs.append(adopted_bin)
331332
except Exception:

0 commit comments

Comments
 (0)