GitNexus/gitnexus/test
Ofek Gabay bfe8a87831
fix: actionable error + docs for pnpm dlx / pnpx native-load crash (#307) (#1967)
* fix: guide pnpm dlx/pnpx users through skipped native install

`pnpm dlx gitnexus serve` (and `pnpx gitnexus`) crash with a raw
`ERR_DLOPEN_FAILED` stack trace because @ladybugdb/core's native addon
(lbugjs.node) is placed by a postinstall script, and dlx/pnpx run
ephemerally without executing lifecycle scripts.

The existing checkLbugNative() guard already catches the missing binary
for serve/mcp/analyze, but its guidance only mentioned bun and
--ignore-scripts. Extend the message to call out the common pnpm dlx /
pnpx case and the fix (`pnpm add -g gitnexus && pnpm approve-builds -g`,
or use npx/npm). Add a matching README troubleshooting section.

This does not make `pnpm dlx` itself work — that requires a runtime
fallback in @ladybugdb/core. It turns the crash into actionable guidance.

Refs #307

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

* fix: add pnpm --allow-build dlx option to native-check guidance

Incorporates collaborator feedback (magyargergo): pnpm's security model
allows `dlx` to run build scripts when you pass `--allow-build` for each
native dep. Add this as the first/preferred pnpm-dlx path in the error
message, README troubleshooting section, and test assertion. Drop the
now-incorrect claim that `pnpm dlx` "cannot be made to work directly".

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: address PR review on pnpm dlx native-load guidance

Replace removed pnpm approve-builds -g with add -g --allow-build flags,
qualify npm 11 npx caveats, use serve in examples, extend load-failure hints,
and assert --allow-build precedes dlx in tests.

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Gergő Magyar <gergomagyar@icloud.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-02 05:54:25 +01:00
..
fixtures fix: COBOL parsing-layer coverage gaps — F17-F23 (#1925) (#1959) 2026-06-01 21:08:07 +01:00
helpers feat(ingestion): tree-sitter node-type/field validation gate + remove dead literals (#1937) 2026-05-31 10:29:41 +01:00
integration fix: COBOL parsing-layer coverage gaps — F17-F23 (#1925) (#1959) 2026-06-01 21:08:07 +01:00
unit fix: actionable error + docs for pnpm dlx / pnpx native-load crash (#307) (#1967) 2026-06-02 05:54:25 +01:00
utils fix: skip Claude augment hook when GitNexus server owns DB (#1493) 2026-05-14 16:39:30 +01:00