Merge pull request #50285 from marsam/feature/async_generator-python35

python3Packages.async_generator: fix build on python3.5
This commit is contained in:
worldofpeace 2018-11-28 23:26:01 -05:00 committed by GitHub
commit 8d88e4f6c7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 3 deletions

View file

@ -1,4 +1,4 @@
{ lib, buildPythonPackage, fetchPypi, pythonOlder, pytest, pytest-asyncio }:
{ lib, buildPythonPackage, fetchPypi, pythonOlder, isPy35, pytest, pytest-asyncio }:
buildPythonPackage rec {
pname = "async_generator";
@ -17,6 +17,9 @@ buildPythonPackage rec {
pytest -W error -ra -v --pyargs async_generator
'';
# disable tests on python3.5 to avoid circular dependency with pytest-asyncio
doCheck = !isPy35;
meta = with lib; {
description = "Async generators and context managers for Python 3.5+";
homepage = https://github.com/python-trio/async_generator;

View file

@ -1,4 +1,4 @@
{ stdenv, buildPythonPackage, fetchPypi, pytest, isPy3k }:
{ stdenv, buildPythonPackage, fetchPypi, pytest, isPy3k, isPy35, async_generator }:
buildPythonPackage rec {
pname = "pytest-asyncio";
version = "0.9.0";
@ -10,7 +10,8 @@ buildPythonPackage rec {
sha256 = "fbd92c067c16111174a1286bfb253660f1e564e5146b39eeed1133315cf2c2cf";
};
buildInputs = [ pytest ];
buildInputs = [ pytest ]
++ stdenv.lib.optionals isPy35 [ async_generator ];
# No tests in archive
doCheck = false;