nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 20.03 52 lines 1.3 kB view raw
1{ aiohttp 2, bottle 3, buildPythonPackage 4, celery 5, certifi 6, django 7, falcon 8, fetchPypi 9, flask 10, iana-etc 11, isPy3k 12, libredirect 13, pyramid 14, rq 15, sanic 16, sqlalchemy 17, stdenv 18, tornado 19, urllib3 20}: 21 22buildPythonPackage rec { 23 pname = "sentry-sdk"; 24 version = "0.13.5"; 25 26 src = fetchPypi { 27 inherit pname version; 28 sha256 = "c6b919623e488134a728f16326c6f0bcdab7e3f59e7f4c472a90eea4d6d8fe82"; 29 }; 30 31 checkInputs = [ django flask tornado bottle rq falcon sqlalchemy ] 32 ++ stdenv.lib.optionals isPy3k [ celery pyramid sanic aiohttp ]; 33 34 propagatedBuildInputs = [ urllib3 certifi ]; 35 36 meta = with stdenv.lib; { 37 homepage = "https://github.com/getsentry/sentry-python"; 38 description = "New Python SDK for Sentry.io"; 39 license = licenses.bsd2; 40 maintainers = with maintainers; [ gebner ]; 41 }; 42 43 # The Sentry tests need access to `/etc/protocols` (the tests call 44 # `socket.getprotobyname('tcp')`, which reads from this file). Normally 45 # this path isn't available in the sandbox. Therefore, use libredirect 46 # to make on eavailable from `iana-etc`. This is a test-only operation. 47 preCheck = '' 48 export NIX_REDIRECTS=/etc/protocols=${iana-etc}/etc/protocols 49 export LD_PRELOAD=${libredirect}/lib/libredirect.so 50 ''; 51 postCheck = "unset NIX_REDIRECTS LD_PRELOAD"; 52}