Skip to content

treewide: migrate from pytestFlagsArray to enabledTestPaths (the trivial ones)#403112

Merged
wolfgangwalther merged 1 commit intoNixOS:stagingfrom
ShamrockLee:pytestFlags-enabledTestPaths-trivial
Jun 12, 2025
Merged

treewide: migrate from pytestFlagsArray to enabledTestPaths (the trivial ones)#403112
wolfgangwalther merged 1 commit intoNixOS:stagingfrom
ShamrockLee:pytestFlags-enabledTestPaths-trivial

Conversation

@ShamrockLee
Copy link
Contributor

This PR migrates Python packages/applications which uses pytestFlagsArray to hold test paths or test items to enabledTestPaths for better __structuredAttrs = true support.

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 6.topic: python Python is a high-level, general-purpose programming language. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. labels Apr 30, 2025
@ShamrockLee ShamrockLee changed the title [wip] (skip ofborg) tree-wide: migrate from pytestFlagsArray to enabledTestPaths (the trivial ones) tree-wide: migrate from pytestFlagsArray to enabledTestPaths (the trivial ones) Apr 30, 2025
@ShamrockLee ShamrockLee marked this pull request as ready for review April 30, 2025 17:34
@nix-owners nix-owners bot requested a review from mweinelt April 30, 2025 17:36
@ShamrockLee ShamrockLee changed the title tree-wide: migrate from pytestFlagsArray to enabledTestPaths (the trivial ones) treewide: migrate from pytestFlagsArray to enabledTestPaths (the trivial ones) Apr 30, 2025
@ShamrockLee ShamrockLee force-pushed the pytestFlags-enabledTestPaths-trivial branch from bdfd11c to 58d4681 Compare April 30, 2025 19:58
@wegank wegank added the 2.status: merge conflict This PR has merge conflicts with the target branch label Jun 9, 2025
@ShamrockLee ShamrockLee force-pushed the pytestFlags-enabledTestPaths-trivial branch from 58d4681 to e5b363e Compare June 12, 2025 13:14
@ShamrockLee
Copy link
Contributor Author

Rebased and resolved merge conflicts.

@ofborg ofborg bot removed the 2.status: merge conflict This PR has merge conflicts with the target branch label Jun 12, 2025
@ShamrockLee ShamrockLee added 2.status: merge conflict This PR has merge conflicts with the target branch backport staging-25.05 and removed 2.status: merge conflict This PR has merge conflicts with the target branch labels Jun 12, 2025
@ShamrockLee ShamrockLee added the 3.skill: trivial This is trivial to complete (typically find-and-replace) label Jun 12, 2025
Copy link
Contributor

@wolfgangwalther wolfgangwalther left a comment

Choose a reason for hiding this comment

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

Only found one bad change, all others look good.

I'm not sure why you split those up in so many commits. I see no benefit for reviewing, but it must be a lot more work for you. Is that for ofborg?

Personally, I'd just create a single treewide commit, ideally with a reproducible command to run to recreate it. And then I'd run nixpkgs-review on it (ok, yeah, too many rebuilds for that, mhhh).

@ShamrockLee
Copy link
Contributor Author

ShamrockLee commented Jun 12, 2025

I'm not sure why you split those up in so many commits. I see no benefit for reviewing, but it must be a lot more work for you. Is that for ofborg?

It was for OfBorg, git-bisect and my prior experience that splitting commits made a PR cleaner, but now a single commit seems much easier to handle considering the number of changes.

@wolfgangwalther
Copy link
Contributor

Interestingly, ofborg doesn't seem to react to those changes. Does it stop doing so after a number of commits maybe (?).

@ShamrockLee ShamrockLee force-pushed the pytestFlags-enabledTestPaths-trivial branch from e5b363e to cb225fe Compare June 12, 2025 13:59
@ShamrockLee
Copy link
Contributor Author

ShamrockLee commented Jun 12, 2025

The PR comments are now buried inside the commit messages. I'll merge them into one to prevent flooding.

@ShamrockLee ShamrockLee force-pushed the pytestFlags-enabledTestPaths-trivial branch from cb225fe to 794f904 Compare June 12, 2025 14:06
@wolfgangwalther
Copy link
Contributor

Obviously, I didn't rebuild 40k packages, but the changes LGTM. Let's merge this while it's non-conflicted.

@wolfgangwalther wolfgangwalther merged commit eff6dd6 into NixOS:staging Jun 12, 2025
15 of 18 checks passed
@nixpkgs-ci
Copy link
Contributor

nixpkgs-ci bot commented Jun 12, 2025

Backport failed for staging-25.05, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin staging-25.05
git worktree add -d .worktree/backport-403112-to-staging-25.05 origin/staging-25.05
cd .worktree/backport-403112-to-staging-25.05
git switch --create backport-403112-to-staging-25.05
git cherry-pick -x 794f904bf3f6a985fcbd8d3a75d29ac7e84c3a50

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.skill: trivial This is trivial to complete (typically find-and-replace) 6.topic: python Python is a high-level, general-purpose programming language. 8.has: port to stable This PR already has a backport to the stable release. 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants