19 buildPythonPackage rec {
20 pname = "oslo-concurrency";
22 format = "setuptools";
25 pname = "oslo.concurrency";
27 hash = "sha256-tS8CtORvXydLkfuOG/xcv5pBjfzUqDvggDRUlePSboo=";
31 # only a small portion of the listed packages are actually needed for running the tests
32 # so instead of removing them one by one remove everything
33 rm test-requirements.txt
35 substituteInPlace oslo_concurrency/tests/unit/test_processutils.py \
36 --replace "/bin/bash" "${bash}/bin/bash" \
37 --replace "/bin/true" "${coreutils}/bin/true" \
38 --replace "/usr/bin/env" "${coreutils}/bin/env" \
39 --replace "/usr/bin/true" "${coreutils}/bin/true"
42 propagatedBuildInputs = [
49 # tests hang for unknown reason and time the build out
60 echo "nameserver 127.0.0.1" > resolv.conf
61 export NIX_REDIRECTS=/etc/protocols=${iana-etc}/etc/protocols:/etc/resolv.conf=$(realpath resolv.conf)
62 export LD_PRELOAD=${libredirect}/lib/libredirect.so
64 stestr run -e <(echo "
65 oslo_concurrency.tests.unit.test_lockutils_eventlet.TestInternalLock.test_fair_lock_with_spawn
66 oslo_concurrency.tests.unit.test_lockutils_eventlet.TestInternalLock.test_fair_lock_with_spawn_n
70 pythonImportsCheck = [ "oslo_concurrency" ];
73 broken = stdenv.isDarwin;
74 description = "Oslo Concurrency library";
75 mainProgram = "lockutils-wrapper";
76 homepage = "https://github.com/openstack/oslo.concurrency";
77 license = licenses.asl20;
78 maintainers = teams.openstack.members;