git.iko.soy/typeable/nixpkgs
on master help sign in
python3Packages.azure-mgmt-commerce: use fetchpypi
commitb18cf1b35a2b2e67645e2518e7bd67e713d1eb97 authorJonathan Ringer <jonringer117@gmail.com> dateTue 6 Oct 2020, 01:07 (6 years ago) parent8a75ad4
1 file changed+17−12
pkgs/development/python-modules/azure-mgmt-commerce/default.nix+17−12
pkgs/development/python-modules/azure-mgmt-commerce/default.nix+17−12
@@ -1,6 +1,6 @@
11{ lib
22, buildPythonPackage
3−, fetchFromGitHub
3+, fetchPypi
44, msrestazure
55, azure-common
66, azure-mgmt-nspkg
@@ -8,34 +8,39 @@
88, isPy3k
99}:
1010
11−buildPythonPackage {
11+buildPythonPackage rec {
1212 pname = "azure-mgmt-commerce";
1313 version = "1.0.1";
1414
15− src = fetchFromGitHub {
16− owner = "Azure";
17− repo = "azure-sdk-for-python";
18− rev = "ee5b47525d6c1eae3b1fd5f65b0421eab62a6e6f";
19− sha256 = "0xzdn7da5c3q5knh033vbsqk36vwbm75cx8vf10x0yj58krb4kn4";
15+ src = fetchPypi {
16+ inherit pname version;
17+ extension = "zip";
18+ sha256 = "1hw4crkgb72ps85m2kz9kf8p2wg9qmaagk3z5nydva9g6bnq93n4";
2019 };
2120
22− preBuild = ''
23− cd ./azure-mgmt-commerce
24− '';
25−
2621 propagatedBuildInputs = [
2722 msrestazure
2823 azure-common
2924 azure-mgmt-nspkg
3025 ];
3126
27+ prePatch = ''
28+ rm -f azure_bdist_wheel.py tox.ini
29+ substituteInPlace setup.py \
30+ --replace "wheel==0.30.0" "wheel"
31+ sed -i "/azure-namespace-package/c\ " setup.cfg
32+ '';
33+
34+ pythonNamespaces = [ "azure.mgmt" ];
35+
3236 # has no tests
3337 doCheck = false;
38+ pythonImportsCheck = [ "azure.mgmt.commerce" ];
3439
3540 meta = with lib; {
3641 description = "This is the Microsoft Azure Commerce Management Client Library";
3742 homepage = "https://github.com/Azure/azure-sdk-for-python";
3843 license = licenses.mit;
39− maintainers = with maintainers; [ mwilsoninsight ];
44+ maintainers = with maintainers; [ mwilsoninsight jonringer ];
4045 };
4146}