From 46fa7ab6863326af795ab34e96cce2719f4961f2 Mon Sep 17 00:00:00 2001 From: Spencer Baugh Date: Tue, 8 May 2018 22:19:22 +0000 Subject: [PATCH 1/3] pythonPackages.outcome: init at 0.1.0a0 --- .../python-modules/outcome/default.nix | 27 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 29 insertions(+) create mode 100644 pkgs/development/python-modules/outcome/default.nix diff --git a/pkgs/development/python-modules/outcome/default.nix b/pkgs/development/python-modules/outcome/default.nix new file mode 100644 index 00000000000..e91925c75d5 --- /dev/null +++ b/pkgs/development/python-modules/outcome/default.nix @@ -0,0 +1,27 @@ +{ lib, buildPythonPackage, fetchPypi, pythonOlder +, attrs +, pytest +}: + +buildPythonPackage rec { + pname = "outcome"; + version = "0.1.0a0"; + disabled = pythonOlder "3.4"; + + src = fetchPypi { + inherit pname version; + sha256 = "0cqwakzigw0602dxlb7c1882jwr8hn5nrxk1l8iwlmzc9whh48wn"; + }; + + checkInputs = [ pytest ]; + propagatedBuildInputs = [ attrs ]; + # Has a test dependency on trio, which depends on outcome. + doCheck = false; + + meta = { + description = "Capture the outcome of Python function calls."; + homepage = https://github.com/python-trio/outcome; + license = with lib.licenses; [ mit asl20 ]; + maintainers = with lib.maintainers; [ catern ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2e8f77d8a90..05d956de788 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -303,6 +303,8 @@ in { oauthenticator = callPackage ../development/python-modules/oauthenticator { }; + outcome = callPackage ../development/python-modules/outcome {}; + plantuml = callPackage ../tools/misc/plantuml { }; Pmw = callPackage ../development/python-modules/Pmw { }; From c983bbb557d5d201015d71868796777fab46d52b Mon Sep 17 00:00:00 2001 From: Spencer Baugh Date: Fri, 11 May 2018 16:38:30 +0000 Subject: [PATCH 2/3] pythonPackages.trustme: init at 0.4.0 --- .../python-modules/trustme/default.nix | 26 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 2 files changed, 28 insertions(+) create mode 100644 pkgs/development/python-modules/trustme/default.nix diff --git a/pkgs/development/python-modules/trustme/default.nix b/pkgs/development/python-modules/trustme/default.nix new file mode 100644 index 00000000000..0c3ccb5258e --- /dev/null +++ b/pkgs/development/python-modules/trustme/default.nix @@ -0,0 +1,26 @@ +{ lib, buildPythonPackage, fetchPypi, cryptography, pytest, pyopenssl, service-identity }: + +buildPythonPackage rec { + pname = "trustme"; + version = "0.4.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "1215vr6l6c0fzsv5gyay82fxd4fidvq2rd94wvjrljs6h2wajazk"; + }; + + checkInputs = [ pytest pyopenssl service-identity ]; + checkPhase = '' + py.test + ''; + propagatedBuildInputs = [ + cryptography + ]; + + meta = { + description = "#1 quality TLS certs while you wait, for the discerning tester"; + homepage = https://github.com/python-trio/trustme; + license = with lib.licenses; [ mit asl20 ]; + maintainers = with lib.maintainers; [ catern ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 05d956de788..7a7616e7fff 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -438,6 +438,8 @@ in { hdf5 = pkgs.hdf5.override { zlib = pkgs.zlib; }; }; + trustme = callPackage ../development/python-modules/trustme {}; + tokenserver = callPackage ../development/python-modules/tokenserver {}; toml = callPackage ../development/python-modules/toml { }; From f78c25239e9aaaec67851ce3a5af150b49d6ac49 Mon Sep 17 00:00:00 2001 From: Spencer Baugh Date: Tue, 8 May 2018 22:19:48 +0000 Subject: [PATCH 3/3] pythonPackages.trio: init at 0.4.0 --- .../python-modules/trio/default.nix | 42 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 44 insertions(+) create mode 100644 pkgs/development/python-modules/trio/default.nix diff --git a/pkgs/development/python-modules/trio/default.nix b/pkgs/development/python-modules/trio/default.nix new file mode 100644 index 00000000000..2bd607170fd --- /dev/null +++ b/pkgs/development/python-modules/trio/default.nix @@ -0,0 +1,42 @@ +{ lib, buildPythonPackage, fetchPypi, pythonOlder +, attrs +, sortedcontainers +, async_generator +, idna +, outcome +, contextvars +, pytest +, pyopenssl +, trustme +}: + +buildPythonPackage rec { + pname = "trio"; + version = "0.4.0"; + disabled = pythonOlder "3.5"; + + src = fetchPypi { + inherit pname version; + sha256 = "0ib1x47knlad9pljb64ywfiv6m3dfrqqjwka6j1b73hixmszb5h4"; + }; + + checkInputs = [ pytest pyopenssl trustme ]; + # It appears that the build sandbox doesn't include /etc/services, and these tests try to use it. + checkPhase = '' + py.test -k 'not test_getnameinfo and not test_SocketType_resolve and not test_getprotobyname' + ''; + propagatedBuildInputs = [ + attrs + sortedcontainers + async_generator + idna + outcome + ] ++ lib.optionals (pythonOlder "3.7") [ contextvars ]; + + meta = { + description = "An async/await-native I/O library for humans and snake people"; + homepage = https://github.com/python-trio/trio; + license = with lib.licenses; [ mit asl20 ]; + maintainers = with lib.maintainers; [ catern ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 7a7616e7fff..4a4717ea6a7 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -440,6 +440,8 @@ in { trustme = callPackage ../development/python-modules/trustme {}; + trio = callPackage ../development/python-modules/trio {}; + tokenserver = callPackage ../development/python-modules/tokenserver {}; toml = callPackage ../development/python-modules/toml { };