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
Commit cd25034
Browse filesBrowse the repository at this point in the historyBrowse files
fix(drivers): handle UNC paths, and give the install lock a per-holder budget
Three review-round gaps, two of them Windows shapes that a macOS suite cannot
notice on its own.
**`installLockPath` broke on a UNC share root.** It special-cased the POSIX and
drive-letter roots but not `\\server\share`, which stripped to
`\\server\share.lock` — naming a *different network share* rather than anything
inside the directory being locked. Two processes installing into a share would
then take different locks, which is the concurrent npm mutation the lock exists
to prevent. Root detection now covers all three shapes and the lock always
lands inside the root.
**The harvesting regex accepted no UNC path.** A Windows error quoting
`\\server\share\node_modules\duckdb\package.json` yielded no roots at all, so a
driver on a share stayed unfindable even though the error named its exact
location. The pattern is now a named export, so the claim is testable from any
platform instead of resting on inspection.
**The lock wait outlasted only one peer.** Every process counts its deadline
from its own start, so a single budget covers a single holder; with three or
more contenders the last one's deadline expired part-way through somebody
else's install and it fell through to an unlocked `performInstall`. The budget
is now per holder — seeing the lock change hands is proof the queue is moving
rather than wedged — with a bounded number of extensions so a machine that
keeps feeding in contenders cannot block a caller indefinitely.
Each test fails with its own fix reverted and passes with it: 1 of 10 for each
Windows shape, 1 of 14 for the multi-peer wait. The multi-peer test spawns real
processes, holds 400ms against a 600ms budget, and asserts none of the three
ran unlocked. 12/12 repeat runs green.
Also hardens the chdir arm per review. It asked for `duckdb`, which the repo's
own `packages/drivers/node_modules` satisfies through the execPath and
module-location roots no matter what the resolver does — it would have passed
while proving nothing. It now uses specifiers that exist nowhere but the tree
each test builds and asserts on an export marker, so a pass establishes which
root satisfied the load.
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01VqnuBDGkh1ZT65Ti7e6DHZ
0 commit comments