Repository navigation
id: give the scaffold test's Roc compile a writable cache (nix sandbox AccessDenied) - #11471
Merged
Merged
Conversation
Roc writes its cache under XDG_CACHE_HOME, else $HOME/.cache. In the nix check sandbox HOME is /homeless-shelter, which cannot be created, so world_new_scaffold_compiles_with_pinned_roc failed id-lib's check with a bare AccessDenied. Point XDG_CACHE_HOME at the test's temp dir, as world_compile.rs already does for real compiles; same for the serve_tests scaffold compile. Closes #11163 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dezren39
marked this pull request as ready for review
November 18, 2026 01:30
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #11163
Before:
cli_tests::world_new_scaffold_compiles_with_pinned_rocfailed id-lib's nix check with "The compiler stopped with the error AccessDenied but did not say why." Roc writes its cache underXDG_CACHE_HOME, falling back to$HOME/.cache. In the nix sandbox, HOME is/homeless-shelter, which can't be created.After: the test points
XDG_CACHE_HOMEat its own temp dir for the Roc compile, which is whatcrates/id-worlds/src/world_compile.rsalready does for every real compile. The serve_tests scaffold compile gets the same line. serve_tests is skipped in nix, so this is only for consistency there.How I checked the cause, with the pinned
nightly-2026-10-04-130536dbinary (sha256 matchesnix/roc.nix):HOME=/homeless-shelter roc checkcreated/homeless-shelter/.cache. I ran as root here, so the directory could be created; the nix build user can't create it.HOME=/proc/nohome roc check(unwritable even for root) never finished.XDG_CACHE_HOMEset to a temp dir passed in 19 ms and put its cache there.Testing: rustfmt (edition 2024) is clean. I couldn't run the test end to end here: it needs the zig-built
host.wasmand a nix build of id-lib, and neither is available in this environment.nix build .#id-libis the confirming run.Generated by Claude Code
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.