Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python3.pkgs.insteon-frontend-home-assistant: unpin setuptools dependency #248859

Merged
merged 1 commit into from
Aug 19, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
{ lib
, buildPythonPackage
, fetchpatch
, fetchPypi
, pythonOlder
, setuptools
, wheel
}:

buildPythonPackage rec {
Expand All @@ -17,8 +19,18 @@ buildPythonPackage rec {
hash = "sha256-R+P4pgKbLvf0mwpSDoujCvlJe/yS+nvSJ7ewLVOOg/0=";
};

patches = [
# https://github.com/pyinsteon/insteon-panel/pull/33
(fetchpatch {
name = "unpin-setuptools.patch";
url = "https://github.com/pyinsteon/insteon-panel/commit/2297eb05668907edd03633f244e5876990e340c7.patch";
hash = "sha256-kTu1+IwDrcdqelyK/vfhxw8MQBis5I1jag7YTytKQhs=";
})
];

nativeBuildInputs = [
setuptools
wheel
Copy link
Member

Choose a reason for hiding this comment

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

Why add wheel given that the patch removes it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good question. The patch removes declaring it as a build dependency in pyproject.toml but it doesn't mean that wheel isn't a dependency. PEP 517 describes that a build backend like setuptools can declare additional build dependencies via the get_requires_for_build_wheel and get_requires_for_build_sdist methods, which setuptools does. It's best practice not to include wheel as a dependency in pyproject.toml because then it will be downloaded even in an sdist build (though that doesn't apply to us in nixpkgs).

];

# upstream has no tests
Expand Down