GitNexus/gitnexus-cursor-integration/hooks
abhigyantrumio 5bacf5a4b6 fix(hooks): distinguish EPERM from ESRCH in PID liveness check
Cursor Bugbot caught a contradiction with the stated design: the bare
`catch` after `process.kill(owner, 0)` was treating EPERM (process exists
but owned by another user) the same as ESRCH (process gone), which would
evict a live slot whenever the lock dir straddled user boundaries.

Inspect the error code: ESRCH → dead, evict; EPERM → still alive, keep
the slot; anything else → assume alive (be conservative under unexpected
failure rather than over-evict).

Applied to all three hook variants.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 20:00:51 +05:30
..
gitnexus-hook.cjs fix(hooks): distinguish EPERM from ESRCH in PID liveness check 2026-05-12 20:00:51 +05:30
hooks.json feat(cursor): upgrade hooks to Cursor 2.4 postToolUse for Read/Grep/Shell coverage (#1467) 2026-05-10 13:29:06 +01:00