Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ stdenv, buildPythonPackage, fetchPypi, dnspython, pycountry, nose }: 2 3buildPythonPackage rec { 4 pname = "FormEncode"; 5 version = "1.3.1"; 6 7 src = fetchPypi { 8 inherit pname version; 9 sha256 = "1xm77h2mds2prlaz0z4nzkx13g61rx5c2v3vpgjq9d5ij8bzb8md"; 10 }; 11 12 buildInputs = [ dnspython pycountry nose ]; 13 14 patchPhase = '' 15 # dnspython3 has been superseded, see its PyPI page 16 substituteInPlace setup.py --replace dnspython3 dnspython 17 ''; 18 19 preCheck = '' 20 # two tests require dns resolving 21 sed -i 's/test_cyrillic_email/noop/' formencode/tests/test_email.py 22 sed -i 's/test_unicode_ascii_subgroup/noop/' formencode/tests/test_email.py 23 ''; 24 25 meta = with stdenv.lib; { 26 description = "FormEncode validates and converts nested structures"; 27 homepage = "http://formencode.org"; 28 license = licenses.mit; 29 }; 30}