lol
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

python312Packages.zope-location: refactor

+40 -12
+40 -12
pkgs/development/python-modules/zope-location/default.nix
··· 1 1 { 2 2 lib, 3 3 buildPythonPackage, 4 - fetchPypi, 4 + fetchFromGitHub, 5 + setuptools, 6 + zope-interface, 5 7 zope-proxy, 8 + zope-schema, 9 + zope-component, 10 + zope-configuration, 11 + unittestCheckHook, 6 12 }: 7 13 8 14 buildPythonPackage rec { 9 - pname = "zope.location"; 15 + pname = "zope-location"; 10 16 version = "5.0"; 17 + pyproject = true; 11 18 12 - src = fetchPypi { 13 - inherit pname version; 14 - hash = "sha256-AW/qk0uX2tKwimTqfy+8PeVduwdMRh9m2HHHC/OqrqU="; 19 + src = fetchFromGitHub { 20 + owner = "zopefoundation"; 21 + repo = "zope.location"; 22 + tag = version; 23 + hash = "sha256-C8tQ4qqzkQx+iU+Pm3iCEchtqOZT/qcYFSzJWzqlhnI="; 15 24 }; 16 25 17 - propagatedBuildInputs = [ zope-proxy ]; 26 + build-system = [ setuptools ]; 18 27 19 - # ignore circular dependency on zope-schema 20 - preBuild = '' 21 - sed -i '/zope.schema/d' setup.py 28 + dependencies = [ 29 + zope-interface 30 + zope-proxy 31 + zope-schema 32 + ]; 33 + 34 + optional-dependencies = { 35 + zcml = [ zope-configuration ]; 36 + component = [ zope-component ]; 37 + }; 38 + 39 + pythonImportsCheck = [ "zope.location" ]; 40 + 41 + nativeCheckInputs = [ unittestCheckHook ]; 42 + 43 + # prevent cirtular import 44 + preCheck = '' 45 + rm src/zope/location/tests/test_configure.py 46 + rm src/zope/location/tests/test_pickling.py 22 47 ''; 23 48 24 - doCheck = false; 49 + unittestFlagsArray = [ "src/zope/location/tests" ]; 50 + 51 + pythonNamespaces = [ "zope" ]; 25 52 26 - meta = with lib; { 53 + meta = { 27 54 homepage = "https://github.com/zopefoundation/zope.location/"; 28 55 description = "Zope Location"; 29 - license = licenses.zpl20; 56 + changelog = "https://github.com/zopefoundation/zope.location/blob/${src.tag}/CHANGES.rst"; 57 + license = lib.licenses.zpl21; 30 58 maintainers = [ ]; 31 59 }; 32 60 }