mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-03-14 11:56:33 +01:00
There is no need to disable Python packages for Python versions that are
no longer in Nixpkgs.
This change was generated using the following script:
pattern='^\s*disabled\s*=\s*pythonOlder\s*"3\.\([0-9]\|10\)"\s*;\s*$'
for f in $(find -name '*.nix'); do
grep -q "$pattern" "$f" || continue
sed -i "/$pattern/d" "$f"
if [ $(grep -c pythonOlder "$f") == 1 ]; then
sed -i '/^\s*pythonOlder,\s*$/d' "$f"
fi
nixfmt "$f"
done
61 lines
1.3 KiB
Nix
61 lines
1.3 KiB
Nix
{
|
|
lib,
|
|
aiomysql,
|
|
aiopg,
|
|
aiosqlite,
|
|
asyncmy,
|
|
asyncpg,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
pytestCheckHook,
|
|
setuptools,
|
|
sqlalchemy,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "databases";
|
|
version = "0.9.0";
|
|
pyproject = true;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "encode";
|
|
repo = "databases";
|
|
tag = version;
|
|
hash = "sha256-Zf9QqBgDhWAnHdNvzjXtri5rdT00BOjc4YTNzJALldM=";
|
|
};
|
|
|
|
nativeBuildInputs = [ setuptools ];
|
|
|
|
propagatedBuildInputs = [ sqlalchemy ];
|
|
|
|
optional-dependencies = {
|
|
postgresql = [ asyncpg ];
|
|
asyncpg = [ asyncpg ];
|
|
aiopg = [ aiopg ];
|
|
mysql = [ aiomysql ];
|
|
aiomysql = [ aiomysql ];
|
|
asyncmy = [ asyncmy ];
|
|
sqlite = [ aiosqlite ];
|
|
aiosqlite = [ aiosqlite ];
|
|
};
|
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
disabledTestPaths = [
|
|
# circular dependency on starlette
|
|
"tests/test_integration.py"
|
|
# TEST_DATABASE_URLS is not set.
|
|
"tests/test_databases.py"
|
|
"tests/test_connection_options.py"
|
|
];
|
|
|
|
pythonImportsCheck = [ "databases" ];
|
|
|
|
meta = {
|
|
description = "Async database support for Python";
|
|
homepage = "https://github.com/encode/databases";
|
|
changelog = "https://github.com/encode/databases/releases/tag/${version}";
|
|
license = lib.licenses.bsd3;
|
|
maintainers = [ ];
|
|
};
|
|
}
|