portfolio: 0.71.2 -> 0.72.2 (#360387)
[NixPkgs.git] / pkgs / development / python-modules / schwifty / default.nix
blobd94adfdc7ba73ae00d86305e4f3e7644b992c347
2   lib,
3   buildPythonPackage,
4   fetchPypi,
6   # build-system
7   hatchling,
8   hatch-vcs,
10   # dependencies
11   importlib-resources,
12   iso3166,
13   pycountry,
14   rstr,
16   # optional-dependencies
17   pydantic,
19   # tests
20   pytestCheckHook,
21   pythonOlder,
24 buildPythonPackage rec {
25   pname = "schwifty";
26   version = "2024.11.0";
27   pyproject = true;
29   disabled = pythonOlder "3.9";
31   src = fetchPypi {
32     inherit pname version;
33     hash = "sha256-0KrtAxaEA7Qz3lFdZj3wlRaUGucBUoUNo6/jwkIlX2o=";
34   };
36   build-system = [
37     hatchling
38     hatch-vcs
39   ];
41   dependencies = [
42     iso3166
43     pycountry
44     rstr
45   ] ++ lib.optionals (pythonOlder "3.12") [ importlib-resources ];
47   optional-dependencies = {
48     pydantic = [ pydantic ];
49   };
51   nativeCheckInputs = [
52     pytestCheckHook
53   ] ++ lib.flatten (lib.attrValues optional-dependencies);
55   pythonImportsCheck = [ "schwifty" ];
57   meta = with lib; {
58     changelog = "https://github.com/mdomke/schwifty/blob/${version}/CHANGELOG.rst";
59     description = "Validate/generate IBANs and BICs";
60     homepage = "https://github.com/mdomke/schwifty";
61     license = licenses.mit;
62     maintainers = with maintainers; [ milibopp ];
63   };