2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
2024-07-27 06:49:29 +00:00
|
|
|
setuptools,
|
2024-06-05 15:53:02 +00:00
|
|
|
flask,
|
|
|
|
flask-login,
|
|
|
|
flask-sqlalchemy,
|
|
|
|
psycopg2,
|
|
|
|
pymysql,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
sqlalchemy,
|
|
|
|
sqlalchemy-i18n,
|
|
|
|
sqlalchemy-utils,
|
2020-07-18 16:06:22 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
2023-01-11 07:51:40 +00:00
|
|
|
pname = "sqlalchemy-continuum";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "1.4.2";
|
|
|
|
pyproject = true;
|
2023-01-11 07:51:40 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.7";
|
2020-07-18 16:06:22 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2024-07-27 06:49:29 +00:00
|
|
|
pname = "sqlalchemy_continuum";
|
2023-01-11 07:51:40 +00:00
|
|
|
inherit version;
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-D9K+efcY7aR8IgaHnZLsTr8YiTZGN7PK8+5dNL0ZyOM=";
|
2020-07-18 16:06:22 +00:00
|
|
|
};
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
build-system = [ setuptools ];
|
|
|
|
|
|
|
|
dependencies = [
|
2020-07-18 16:06:22 +00:00
|
|
|
sqlalchemy
|
|
|
|
sqlalchemy-utils
|
|
|
|
];
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
optional-dependencies = {
|
2024-06-05 15:53:02 +00:00
|
|
|
flask = [ flask ];
|
|
|
|
flask-login = [ flask-login ];
|
|
|
|
flask-sqlalchemy = [ flask-sqlalchemy ];
|
|
|
|
i18n = [ sqlalchemy-i18n ];
|
2023-01-11 07:51:40 +00:00
|
|
|
};
|
2020-07-18 16:06:22 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2023-01-11 07:51:40 +00:00
|
|
|
psycopg2
|
|
|
|
pymysql
|
2020-07-18 16:06:22 +00:00
|
|
|
pytestCheckHook
|
2024-07-27 06:49:29 +00:00
|
|
|
] ++ lib.flatten (lib.attrValues optional-dependencies);
|
2023-01-11 07:51:40 +00:00
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
preCheck = ''
|
|
|
|
# Indicate tests that we don't have a database server at hand
|
|
|
|
export DB=sqlite
|
|
|
|
'';
|
2023-03-04 12:14:45 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "sqlalchemy_continuum" ];
|
2020-07-18 16:06:22 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Versioning and auditing extension for SQLAlchemy";
|
2023-01-11 07:51:40 +00:00
|
|
|
homepage = "https://github.com/kvesteri/sqlalchemy-continuum/";
|
|
|
|
changelog = "https://github.com/kvesteri/sqlalchemy-continuum/blob/${version}/CHANGES.rst";
|
2020-07-18 16:06:22 +00:00
|
|
|
license = licenses.bsd3;
|
2023-01-11 07:51:40 +00:00
|
|
|
maintainers = with maintainers; [ ];
|
2020-07-18 16:06:22 +00:00
|
|
|
};
|
|
|
|
}
|