You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
host-setup: menu.sh and menu.ps1 hub-cache locks do not coordinate across tools #1094
host-setup/menu.sh locks the shared --dir hub cache with a flock on $DIR/hub.lock. host-setup/menu.ps1 locks the same cache with a named .NET Mutex, keyed off the directory path (Get-HubMutexName). These are two
independent, non-interoperating locking primitives: a flock on a file
descriptor and a named kernel/CLR mutex object share no coordination
mechanism at all.
If menu.sh and menu.ps1 are ever run concurrently against the same --dir/-Dir on one machine (plausible on a host with both bash and
PowerShell Core installed, or under WSL), one tool's fetch/cleanup can
remove or rewrite the shared hub tree while the other tool is still
reading it, with neither lock aware of the other.
This is a real gap, but a heavier design lift than PR #1091's own scope
(closing concrete rule-6 git-command bypasses): a shared protocol would need
either a common cross-platform lock primitive both scripts use identically,
or a documented convention that the two tools never target the same --dir
concurrently. Tracked here for a follow-up pass rather than fixed inline.
Activity
Lock menu.ps1's Hub Cache Through hub.lock So It Coordinates with men…
Promote develop to main: Lock menu.ps1's Hub Cache Through hub.lock (#…