Skip to content

python3Packages.ploomber-extension: disable tests that fail on Darwin#407133

Merged
GaetanLepage merged 1 commit intoNixOS:masterfrom
sarahec:ploomber-ext-sandbox-darwin
May 15, 2025
Merged

python3Packages.ploomber-extension: disable tests that fail on Darwin#407133
GaetanLepage merged 1 commit intoNixOS:masterfrom
sarahec:ploomber-ext-sandbox-darwin

Conversation

@sarahec
Copy link
Contributor

@sarahec sarahec commented May 14, 2025

Certain tests are failing with "Operation not permitted" when run with sandbox=true or sandbox=relaxed on Darwin. Thi disables those tests only on Darwin.

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@github-actions github-actions bot added the 6.topic: python Python is a high-level, general-purpose programming language. label May 14, 2025
@sarahec sarahec added the 6.topic: darwin Running or building packages on Darwin label May 14, 2025
@sarahec sarahec force-pushed the ploomber-ext-sandbox-darwin branch 2 times, most recently from c98bf88 to 9e24891 Compare May 14, 2025 19:31
@github-actions github-actions bot added 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels May 14, 2025
@nix-owners nix-owners bot requested a review from pacien May 14, 2025 19:40
@sarahec
Copy link
Contributor Author

sarahec commented May 14, 2025

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 407133


x86_64-linux

✅ 4 packages built:
  • python312Packages.ploomber-extension
  • python312Packages.ploomber-extension.dist
  • python313Packages.ploomber-extension
  • python313Packages.ploomber-extension.dist

@sarahec sarahec requested a review from GaetanLepage May 14, 2025 20:08
@sarahec sarahec force-pushed the ploomber-ext-sandbox-darwin branch 2 times, most recently from 1295347 to 5fae024 Compare May 15, 2025 05:12
@sarahec
Copy link
Contributor Author

sarahec commented May 15, 2025

The nixfmt check seems to be broken -- it's looking at the wrong package. I applied nixfmt-rfc-style and git diff --check before submitting.

@sarahec sarahec force-pushed the ploomber-ext-sandbox-darwin branch 2 times, most recently from 82f6265 to 35b1aea Compare May 15, 2025 05:25
@winterqt
Copy link
Member

The nixfmt check seems to be broken -- it's looking at the wrong package. I applied nixfmt-rfc-style and git diff --check before submitting.

Let me take a look at it if it fails even this time.

@sarahec
Copy link
Contributor Author

sarahec commented May 15, 2025

If there are any more changes I'll have to do them in the morning. I need to go to bed before I make any more dumb mistakes.

@github-actions github-actions bot added 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. and removed 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels May 15, 2025
@winterqt
Copy link
Member

Formatting CI wasn't your fault -- see #407248. I retriggered a test merge and restarted the job, it should pass now.

Copy link
Contributor

@GaetanLepage GaetanLepage left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: stdenv should be at the top, right after lib.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Got it. Thank you.

@GaetanLepage
Copy link
Contributor

nixpkgs-review result

Generated using nixpkgs-review-gha

Command: nixpkgs-review pr 407133

Logs: https://github.com/GaetanLepage/nixpkgs-review-gha/actions/runs/15043290856


x86_64-darwin

✅ 4 packages built:
  • python312Packages.ploomber-extension
  • python312Packages.ploomber-extension.dist
  • python313Packages.ploomber-extension
  • python313Packages.ploomber-extension.dist

aarch64-darwin

✅ 4 packages built:
  • python312Packages.ploomber-extension
  • python312Packages.ploomber-extension.dist
  • python313Packages.ploomber-extension
  • python313Packages.ploomber-extension.dist

@sarahec
Copy link
Contributor Author

sarahec commented May 15, 2025

@winterqt I switched to !stdenv.isDarwin as you suggested.

@sarahec sarahec force-pushed the ploomber-ext-sandbox-darwin branch from 35b1aea to 61c8467 Compare May 15, 2025 16:45
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
doCheck = !stdenv.isDarwin;
doCheck = !stdenv.buildPlatform.isDarwin;

otherwise it will be changed by treewide PRs like #341407 or #386584

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

@sarahec sarahec force-pushed the ploomber-ext-sandbox-darwin branch from 61c8467 to 43a0e34 Compare May 15, 2025 18:24
@sarahec
Copy link
Contributor Author

sarahec commented May 15, 2025

@winterqt Turns out stdenv.isDarwin is deprecated and you should use stdenv.hostPlatform.isDarwin see #341407

@winterqt
Copy link
Member

Oh, I completely forgot about that PR (and I guess so did a lot of other people). Thanks!

@GaetanLepage
Copy link
Contributor

nixpkgs-review result

Generated using nixpkgs-review-gha

Command: nixpkgs-review pr 407133

Logs: https://github.com/GaetanLepage/nixpkgs-review-gha/actions/runs/15054269946


x86_64-darwin

✅ 4 packages built:
  • python312Packages.ploomber-extension
  • python312Packages.ploomber-extension.dist
  • python313Packages.ploomber-extension
  • python313Packages.ploomber-extension.dist

aarch64-darwin

✅ 4 packages built:
  • python312Packages.ploomber-extension
  • python312Packages.ploomber-extension.dist
  • python313Packages.ploomber-extension
  • python313Packages.ploomber-extension.dist

Copy link
Contributor

@GaetanLepage GaetanLepage left a comment

Choose a reason for hiding this comment

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

LGTM thankjs

@GaetanLepage GaetanLepage merged commit 7e59443 into NixOS:master May 15, 2025
18 of 21 checks passed
@sarahec sarahec deleted the ploomber-ext-sandbox-darwin branch May 15, 2025 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: darwin Running or building packages on Darwin 6.topic: python Python is a high-level, general-purpose programming language. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants