1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 pythonAtLeast,
6
7 # build-system
8 setuptools,
9
10 # dependencies
11 param,
12 pyyaml,
13 requests,
14
15 # tests
16 pytestCheckHook,
17}:
18
19buildPythonPackage rec {
20 pname = "pyct";
21 version = "0.5.0";
22 pyproject = true;
23
24 src = fetchPypi {
25 inherit pname version;
26 hash = "sha256-3Z9KxcvY43w1LAQDYGLTxfZ+/sdtQEdh7xawy/JqpqA=";
27 };
28
29 build-system = [
30 setuptools
31 ];
32
33 dependencies = [
34 param
35 pyyaml
36 requests
37 ];
38
39 nativeCheckInputs = [
40 pytestCheckHook
41 ];
42 # Only the command line doesn't work on with Python 3.12, due to usage of
43 # deprecated distutils module. Not disabling it totally.
44 disabledTestPaths = lib.optionals (pythonAtLeast "3.12") [
45 "pyct/tests/test_cmd.py"
46 ];
47
48 pythonImportsCheck = [ "pyct" ];
49
50 meta = {
51 description = "ClI for Python common tasks for users";
52 mainProgram = "pyct";
53 homepage = "https://github.com/pyviz/pyct";
54 changelog = "https://github.com/pyviz-dev/pyct/releases/tag/v${version}";
55 license = lib.licenses.bsd3;
56 maintainers = [ ];
57 };
58}