Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / tinydb / default.nix
blob2786018b99adf00c56be3eaa8fea29d347b4cc79
1 { lib
2 , buildPythonPackage
3 , pythonOlder
4 , fetchFromGitHub
5 , poetry-core
6 , pytestCheckHook
7 , pycodestyle
8 , pyyaml
9 }:
11 buildPythonPackage rec {
12   pname = "tinydb";
13   version = "4.8.0";
14   disabled = pythonOlder "3.5";
15   format = "pyproject";
17   src = fetchFromGitHub {
18     owner = "msiemens";
19     repo = pname;
20     rev = "refs/tags/v${version}";
21     hash = "sha256-sdWcpkjC8LtOI1k0Wyk4vLXBcwYe1vuQON9J7P8JPxA=";
22   };
24   nativeBuildInputs = [
25     poetry-core
26   ];
28   postPatch = ''
29     substituteInPlace pytest.ini \
30       --replace "--cov-append --cov-report term --cov tinydb" ""
31   '';
33   nativeCheckInputs = [
34     pytestCheckHook
35     pycodestyle
36     pyyaml
37   ];
39   pythonImportsCheck = [ "tinydb" ];
41   meta = with lib; {
42     description = "Lightweight document oriented database written in Python";
43     homepage = "https://tinydb.readthedocs.org/";
44     changelog = "https://tinydb.readthedocs.io/en/latest/changelog.html";
45     license = licenses.mit;
46     maintainers = with maintainers; [ marcus7070 ];
47   };