1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, poetry-core 5, python 6, pythonOlder 7}: 8 9buildPythonPackage rec { 10 pname = "async-dns"; 11 version = "2.0.0"; 12 disabled = pythonOlder "3.6"; 13 format = "pyproject"; 14 15 src = fetchFromGitHub { 16 owner = "gera2ld"; 17 repo = "async_dns"; 18 rev = "v${version}"; 19 sha256 = "0vn7hxvpzikd7q61a27fwzal4lwsra2063awyr6fjpy6lh3cjdwf"; 20 }; 21 22 nativeBuildInputs = [ 23 poetry-core 24 ]; 25 26 checkPhase = '' 27 export HOME=$TMPDIR 28 # Test needs network access 29 rm -r tests/resolver 30 ${python.interpreter} -m unittest 31 ''; 32 33 pythonImportsCheck = [ "async_dns" ]; 34 35 meta = with lib; { 36 description = "Python DNS library"; 37 homepage = "https://github.com/gera2ld/async_dns"; 38 license = with licenses; [ mit ]; 39 maintainers = with maintainers; [ fab ]; 40 }; 41}