Merge pull request #104253 from meatcar/sqlite-utils-3.0

pythonPackages.sqlite-utils: depend on sqlite-fts4
This commit is contained in:
Kevin Cox 2020-12-20 06:18:59 -05:00 committed by GitHub
commit 0d42077f34
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 45 additions and 3 deletions

View File

@ -0,0 +1,31 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, isPy3k
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "sqlite-fts4";
version = "1.0.1";
disabled = !isPy3k;
src = fetchFromGitHub {
owner = "simonw";
repo = pname;
rev = version;
sha256 = "15r1mijk306fpm61viry5wjhqyxlbqqdk4nfcd901qarx7vqypgy";
};
checkInputs = [
pytestCheckHook
];
meta = with lib; {
description = "Custom Python functions for working with SQLite FTS4";
homepage = "https://github.com/simonw/sqlite-fts4";
license = licenses.asl20;
maintainers = with maintainers; [ meatcar ];
};
}

View File

@ -1,19 +1,22 @@
{ lib
, buildPythonPackage
, fetchPypi
, isPy3k
, pythonOlder
, click
, click-default-group
, sqlite-fts4
, tabulate
, pytestCheckHook
, pytestrunner
, black
, hypothesis
, sqlite
}:
buildPythonPackage rec {
pname = "sqlite-utils";
version = "3.0";
disabled = !isPy3k;
disabled = pythonOlder "3.6";
src = fetchPypi {
inherit pname version;
@ -23,6 +26,7 @@ buildPythonPackage rec {
propagatedBuildInputs = [
click
click-default-group
sqlite-fts4
tabulate
];
@ -30,13 +34,19 @@ buildPythonPackage rec {
pytestCheckHook
pytestrunner
black
hypothesis
];
# disabled until upstream updates tests
disabledTests = lib.optionals (lib.versionAtLeast sqlite.version "3.34.0") [
"test_optimize"
];
meta = with lib; {
description = "Python CLI utility and library for manipulating SQLite databases";
homepage = "https://github.com/simonw/sqlite-utils";
license = licenses.asl20;
maintainers = [ maintainers.meatcar ];
maintainers = with maintainers; [ meatcar ];
};
}

View File

@ -7034,6 +7034,7 @@ in {
sqlitedict = callPackage ../development/python-modules/sqlitedict { };
sqlite-fts4 = callPackage ../development/python-modules/sqlite-fts4 { };
sqlite-utils = callPackage ../development/python-modules/sqlite-utils { };
sqlmap = callPackage ../development/python-modules/sqlmap { };