summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/countryinfo/default.nix
blob: 0db9aead3932f07b0c7a1601c6db5ecc6919db07 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
{
  lib,
  buildPythonPackage,
  fetchFromGitHub,
  poetry-core,
  pydantic,
  typer,
  pytestCheckHook,
}:
buildPythonPackage rec {
  pname = "countryinfo";
  version = "1.0.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "porimol";
    repo = "countryinfo";
    tag = "v${version}";
    hash = "sha256-Y4nJnjXg8raJx2f00DFMktdcWoLO09wqTFK6Fc8RKSI=";
  };

  build-system = [ poetry-core ];

  patches = [ ./fix-pyproject-file.patch ];

  dependencies = [
    pydantic
    typer
  ];

  pythonRelaxDeps = [ "typer" ];

  pythonImportsCheck = [ "countryinfo" ];

  nativeCheckInputs = [ pytestCheckHook ];

  meta = {
    homepage = "https://github.com/porimol/countryinfo";
    description = "Data about countries, ISO info and states/provinces within them";
    license = lib.licenses.mit;
    maintainers = with lib.maintainers; [
      cizniarova
    ];
  };
}