2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
2023-11-16 04:20:00 +00:00
|
|
|
, fetchFromGitHub
|
2021-09-18 10:52:07 +00:00
|
|
|
, packaging
|
2023-11-16 04:20:00 +00:00
|
|
|
, setuptools
|
2021-06-04 09:07:49 +00:00
|
|
|
, setuptools-scm
|
2021-09-18 10:52:07 +00:00
|
|
|
, shapely
|
|
|
|
, sqlalchemy
|
2022-08-12 12:06:08 +00:00
|
|
|
, alembic
|
2021-09-18 10:52:07 +00:00
|
|
|
, pytestCheckHook
|
2022-09-09 14:08:57 +00:00
|
|
|
, pythonOlder
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2022-09-09 14:08:57 +00:00
|
|
|
pname = "geoalchemy2";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "0.14.3";
|
2023-11-16 04:20:00 +00:00
|
|
|
pyproject = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-09-09 14:08:57 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "geoalchemy";
|
|
|
|
repo = "geoalchemy2";
|
|
|
|
rev = "refs/tags/${version}";
|
2024-01-02 11:29:13 +00:00
|
|
|
hash = "sha256-L3/gLbiEF2VEqyhfVPnREMUPFbf9cD3tqGJ+AbThPkQ=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
nativeBuildInputs = [
|
2023-11-16 04:20:00 +00:00
|
|
|
setuptools
|
2021-09-18 10:52:07 +00:00
|
|
|
setuptools-scm
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
sqlalchemy
|
2023-11-16 04:20:00 +00:00
|
|
|
packaging
|
2021-09-18 10:52:07 +00:00
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-08-12 12:06:08 +00:00
|
|
|
alembic
|
2021-09-18 10:52:07 +00:00
|
|
|
pytestCheckHook
|
2023-11-16 04:20:00 +00:00
|
|
|
] ++ passthru.optional-dependencies.shapely;
|
2021-09-18 10:52:07 +00:00
|
|
|
|
|
|
|
disabledTestPaths = [
|
2023-11-16 04:20:00 +00:00
|
|
|
# tests require live databases
|
2021-09-18 10:52:07 +00:00
|
|
|
"tests/gallery/test_decipher_raster.py"
|
|
|
|
"tests/gallery/test_length_at_insert.py"
|
2023-11-16 04:20:00 +00:00
|
|
|
"tests/gallery/test_insert_raster.py"
|
|
|
|
"tests/gallery/test_orm_mapped_v2.py"
|
|
|
|
"tests/gallery/test_specific_compilation.py"
|
2021-09-18 10:52:07 +00:00
|
|
|
"tests/gallery/test_summarystatsagg.py"
|
|
|
|
"tests/gallery/test_type_decorator.py"
|
|
|
|
"tests/test_functional.py"
|
2022-04-27 09:35:20 +00:00
|
|
|
"tests/test_functional_postgresql.py"
|
2023-11-16 04:20:00 +00:00
|
|
|
"tests/test_functional_mysql.py"
|
2022-08-12 12:06:08 +00:00
|
|
|
"tests/test_alembic_migrations.py"
|
2023-11-16 04:20:00 +00:00
|
|
|
"tests/test_pickle.py"
|
2022-04-27 09:35:20 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"geoalchemy2"
|
2021-09-18 10:52:07 +00:00
|
|
|
];
|
2020-07-18 16:06:22 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
passthru.optional-dependencies = {
|
|
|
|
shapely = [ shapely ];
|
|
|
|
};
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2021-09-18 10:52:07 +00:00
|
|
|
description = "Toolkit for working with spatial databases";
|
2023-11-16 04:20:00 +00:00
|
|
|
homepage = "https://geoalchemy-2.readthedocs.io/";
|
2023-07-15 17:15:38 +00:00
|
|
|
changelog = "https://github.com/geoalchemy/geoalchemy2/releases/tag/${version}";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.mit;
|
2023-11-16 04:20:00 +00:00
|
|
|
maintainers = with maintainers; [ nickcao ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|