python310Packages.posthog: init at 3.0.1

This commit is contained in:
happysalada 2023-07-08 15:24:52 +08:00 committed by Yt
parent fbcad28629
commit ab7b093937
2 changed files with 64 additions and 0 deletions

View file

@ -0,0 +1,62 @@
{ lib
, stdenv
, buildPythonPackage
, fetchFromGitHub
# build inputs
, requests
, six
, monotonic
, backoff
, python-dateutil
# check inputs
, mock
, freezegun
, pylint
, flake8
, coverage
, pytest
}:
let
pname = "posthog";
version = "3.0.1";
in
buildPythonPackage {
inherit pname version;
format = "setuptools";
src = fetchFromGitHub {
owner = "PostHog";
repo = "posthog-python";
rev = "refs/tags/v${version}";
hash = "sha256-GSHsa05DUcbIHg1HCoIn8d4NZoG+Iddqfgod2nP4fX0=";
};
propagatedBuildInputs = [
requests
six
monotonic
backoff
python-dateutil
];
nativeCheckInputs = [
mock
freezegun
pylint
flake8
coverage
pytest
];
pythonImportsCheck = [
"posthog"
];
meta = with lib; {
description = "Official PostHog python library";
homepage = "https://github.com/PostHog/posthog-python";
changelog = "https://github.com/PostHog/posthog-python/releases/tag/v${version}";
license = licenses.mit;
maintainers = with maintainers; [ happysalada ];
};
}

View file

@ -8180,6 +8180,8 @@ self: super: with self; {
posix_ipc = callPackage ../development/python-modules/posix_ipc { };
posthog = callPackage ../development/python-modules/posthog { };
pot = callPackage ../development/python-modules/pot { };
potentials = callPackage ../development/python-modules/potentials { };