1{ lib, stdenv, buildPythonPackage, fetchPypi, pytest, hypothesis, zope_interface
2, pympler, coverage, six, clang }:
3
4buildPythonPackage rec {
5 pname = "attrs";
6 version = "18.1.0";
7
8 src = fetchPypi {
9 inherit pname version;
10 sha256 = "e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b";
11 };
12
13 # macOS needs clang for testing
14 checkInputs = [
15 pytest hypothesis zope_interface pympler coverage six
16 ] ++ lib.optionals (stdenv.isDarwin) [ clang ];
17
18 checkPhase = ''
19 py.test
20 '';
21
22 # To prevent infinite recursion with pytest
23 doCheck = false;
24
25 meta = with lib; {
26 description = "Python attributes without boilerplate";
27 homepage = https://github.com/hynek/attrs;
28 license = licenses.mit;
29 };
30}