Skip to content

chore: Enable Nix sandbox tests where applicable#432

Closed
shivaraj-bh wants to merge 4 commits intomainfrom
test-and-clippy
Closed

chore: Enable Nix sandbox tests where applicable#432
shivaraj-bh wants to merge 4 commits intomainfrom
test-and-clippy

Conversation

@shivaraj-bh
Copy link
Member

@shivaraj-bh shivaraj-bh commented Mar 5, 2025

No description provided.

The clippy issue was on nightly. As of
#427 we are no longer on nightly
@shivaraj-bh shivaraj-bh mentioned this pull request Mar 5, 2025
6 tasks
Comment on lines +52 to +57
# FIXME: This should pass in the sandbox
# > ❄\u{fe0f} nix -j auto eval --json --override-input flake ../.. --override-input flake-schemas /nix/store/0npxvlidr0w1b99lrvcmd2wd46y2kibh-flake-schemas --override-input systems /nix/store/g1pv78p6lk92hjzr7syrcihvj4rx1fnz-source --no-write-lock-file \'/nix/store/qm8q4kylp1jy68k34c2bskpamxgyc9ix-source#contents.excludingOutputPaths\' --quiet --quiet\u{fe0f}
# > error: experimental Nix feature \'nix-command\' is disabled; use \'--extra-experimental-features nix-command\' to override
# > Error: Unable to fetch flake
"--skip=command::show::om_show_local"
]);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@srid This could be a potential bug. I even tried looking at how om ci works, but even that uses the same NixCmd::Default, so it is likely that even om ci doesn’t automatically apply the experimental-features when not enabled by default.

We don’t have a similar om_ci_local test (that can run in Nix sandbox), which could be why it went undetected.

Copy link
Member

@srid srid Mar 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

EDIT: This happens on macOS only.

Is the error message in FIXME accurate? Because, when I allow om_show_local, it presents a different error message:

image

@srid
Copy link
Member

srid commented Mar 5, 2025

Thanks. I'd really prefer to have the clippy change on a commit of its own (either in this PR or different PR), so that the history remains clean for debugging issues in future.

@shivaraj-bh
Copy link
Member Author

Moved clippy changes to #433

@shivaraj-bh shivaraj-bh changed the title chore: Enable Nix sandbox tests where applicable; Enable clippy chore: Enable Nix sandbox tests where applicable Mar 5, 2025
@srid
Copy link
Member

srid commented Mar 5, 2025

Note: once #433 is merged, we may be able to replace the om.yaml run with rust-flake clippy check (if all the crates are being autowired).

Copy link
Member

@srid srid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On second thought, I'm not sure if we should even bother to do this if several tests are being disabled anyway (for e.g., due to the fact that some "requires networking").

@srid
Copy link
Member

srid commented Mar 10, 2025

See also #397

We should run or the other, not both. If we can't run the full suite of tests in Nix, let's run tests outside of Nix only.

@srid srid closed this Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants