Skip to content

python3Packages: Use buildPythonPackage within the package set#194100

Merged
mweinelt merged 36 commits intoNixOS:stagingfrom
mweinelt:python-fixes
Oct 2, 2022
Merged

python3Packages: Use buildPythonPackage within the package set#194100
mweinelt merged 36 commits intoNixOS:stagingfrom
mweinelt:python-fixes

Conversation

@mweinelt
Copy link
Member

@mweinelt mweinelt commented Oct 2, 2022

Description of changes

Libraries should be built using buildPythonPackage. Migrate pure applications out of the python package set, create top-level attributes for others.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • 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/)
  • 22.11 Release Notes (or backporting 22.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
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

Reformat, tried to enable tests but we miss a dependency, added
pythonImportsCheck. Added top-level attribute to expose executables.
Also enables tests and fixes import check module name.
Build using poetry-core, enabled tests, expose as top-level attribute.
This is a commandline tool, that does not advertise itself as as
consumable library, so it does not belong into the python package set.

Also fetch from git, so we can enable the tests.
@github-actions github-actions bot added the 6.topic: python Python is a high-level, general-purpose programming language. label Oct 2, 2022
and expose as top-level attribute.
Does not provide a library interface that could be imported and as such
has no place within the python package set.
and expose griffe as top-level attribute.
It's an application with no visible library surface, so it has no place
in the python package set.
and add a top-level attribute. The package is broken and needs an
updated patch, but that does not mean this change is wrong.
This is a CLI client and not a library and as such it has no place in
the python package set.
Was introduced in 2016 with only a top-level attribute, which got
removed in the same year, so hasn't been used since.

Also last commit in 2013, uses python2 print statements, so it has to
go.
and expose as ironicclient top-level attribute.
@ofborg ofborg bot added 8.has: clean-up This PR removes packages or removes other cruft 8.has: package (new) This PR adds a new package 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. labels Oct 2, 2022
@mweinelt mweinelt merged commit d96640a into NixOS:staging Oct 2, 2022
@mweinelt mweinelt deleted the python-fixes branch October 2, 2022 20:31
@FRidh
Copy link
Member

FRidh commented Oct 3, 2022

Thank you! I noticed also an increasing amount of applications sneaking into the package set. Good to have this cleared out.

Note we could add a test in the fix point of python-packages to ensure all derivations are packages and not applications.

@FRidh
Copy link
Member

FRidh commented Oct 3, 2022

See #194205

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

Labels

6.topic: python Python is a high-level, general-purpose programming language. 8.has: clean-up This PR removes packages or removes other cruft 8.has: package (new) This PR adds a new package 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.

3 participants