summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert Schütz <nix@dotlambda.de>2021-12-29 14:33:32 +0000
committerJonathan Ringer <jonringer@users.noreply.github.com>2021-12-29 18:35:28 -0800
commit871ec449761cd2ea3b638dc4e2c0a43cd706401a (patch)
tree42d341dba54ccfcd7997011b8d066fc6b007ce06
parent3ff5348c38a2b798f3e16b1fc4236e1c070f23a5 (diff)
python3Packages.trio-asyncio: init at 0.12.0
-rw-r--r--pkgs/development/python-modules/trio-asyncio/default.nix47
-rw-r--r--pkgs/top-level/python-packages.nix2
2 files changed, 49 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/trio-asyncio/default.nix b/pkgs/development/python-modules/trio-asyncio/default.nix
new file mode 100644
index 000000000000..f6feb789690d
--- /dev/null
+++ b/pkgs/development/python-modules/trio-asyncio/default.nix
@@ -0,0 +1,47 @@
+{ lib
+, buildPythonPackage
+, fetchPypi
+, trio
+, outcome
+, sniffio
+, pytest-trio
+, pytestCheckHook
+}:
+
+buildPythonPackage rec {
+ pname = "trio-asyncio";
+ version = "0.12.0";
+
+ src = fetchPypi {
+ pname = "trio_asyncio";
+ inherit version;
+ sha256 = "824be23b0c678c0df942816cdb57b92a8b94f264fffa89f04626b0ba2d009768";
+ };
+
+ postPatch = ''
+ substituteInPlace setup.py \
+ --replace "'pytest-runner'" ""
+ '';
+
+ propagatedBuildInputs = [
+ trio
+ outcome
+ sniffio
+ ];
+
+ checkInputs = [
+ pytest-trio
+ pytestCheckHook
+ ];
+
+ disabledTestPaths = [
+ "tests/python" # tries to import internal API test.test_asyncio
+ ];
+
+ meta = with lib; {
+ description = "Re-implementation of the asyncio mainloop on top of Trio";
+ homepage = "https://github.com/python-trio/trio-asyncio";
+ license = with licenses; [ asl20 /* or */ mit ];
+ maintainers = with maintainers; [ dotlambda ];
+ };
+}
diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix
index 3e8075885a75..2860bee53083 100644
--- a/pkgs/top-level/python-packages.nix
+++ b/pkgs/top-level/python-packages.nix
@@ -9750,6 +9750,8 @@ in {
trio = callPackage ../development/python-modules/trio { };
+ trio-asyncio = callPackage ../development/python-modules/trio-asyncio { };
+
trueskill = callPackage ../development/python-modules/trueskill { };
trustme = callPackage ../development/python-modules/trustme { };