Repository navigation
fix: fall back to wrappers when bun compile fails - #412
malikrohail wants to merge 2 commits into
Conversation
|
Great work on this PR! We hit a related but distinct issue on WSL2 (filed as #494). Your PR fixes: compile failure → wrapper fallback. ✅ Our additional finding: Even when compile succeeds, Second issue we found: If the system has Our workaround: A bash wrapper (~80 lines) that uses Would be happy to contribute this as a follow-up PR if useful. |
I will patch a commit with the fixes you just mentioned momentarily. |
|
@FeilixX can you test it now pls? |
|
@malikrohail Tested your PR in an isolated git worktree. Here's what I found: Good news: The Bad news: The CLI still times out because Root cause — Bun vs Node.js proxy behavior difference: Bun automatically applies
Your Simplest fix: Add // In ensureServer / startServer:
const loopbackEnv = { ...process.env, NO_PROXY: '127.0.0.1,localhost' };Our env: WSL2 Ubuntu 24.04, Bun 1.3.11, |
|
Thanks for this. The branch combines the virtiofs fallback with separate WSL behavior and would omit parts of the current five-artifact build flow. Split the WSL work, rebase the fallback onto the current build script, preserve all artifacts, and verify virtiofs and WSL paths separately. |
|
Thanks for this, @malikrohail. The fix is now on main: scripts/build.sh runs under set -e and setup no longer masks a failed build with || true, so a failed compile no longer reports success (already on main as of v1.91.16.0). Closing as superseded; if you still see the problem on the latest gstack, please open an issue with ./setup --status output. |
Summary
Fixes the failure mode behind #407 where
bun build --compilecan fail on virtiofs/devcontainer mounts but./setupstill reports success.What changed
scripts/build-artifacts.sh|| truebuild tail with explicitbuild_or_wraphandlingbun build --compilefails, write executablebun runwrappers for:browse/dist/browsebrowse/dist/find-browsebin/gstack-global-discovertest/gen-skill-docs.test.tsWhy this fixes the bug
On virtiofs mounts, Bun can fail the final rename step for compiled binaries. The old
buildcommand hid that failure behind|| true, sosetupcould continue with stale artifacts.This change makes the failure explicit and recovers by installing wrapper entrypoints instead of leaving stale binaries in place.
Verification
bun run buildbun run gen:skill-docs --dry-runbun test test/gen-skill-docs.test.ts -t "build script validation"bun testRefs #407