1{
2 buildPythonPackage,
3 fetchFromGitHub,
4 lib,
5 jinja2,
6 mock,
7 packaging,
8 ply,
9 pytestCheckHook,
10 pythonOlder,
11 setuptools,
12 six,
13}:
14
15buildPythonPackage rec {
16 pname = "stone";
17 version = "3.3.9";
18 pyproject = true;
19
20 disabled = pythonOlder "3.7";
21
22 src = fetchFromGitHub {
23 owner = "dropbox";
24 repo = "stone";
25 tag = "v${version}";
26 hash = "sha256-3tUV2JrE3S2Tj/9aHvzfBTkIWUmWzkWNsVLr5yWRE/Q=";
27 };
28
29 postPatch = ''
30 substituteInPlace setup.py \
31 --replace-fail "'pytest-runner == 5.3.2'," ""
32 '';
33
34 build-system = [ setuptools ];
35
36 dependencies = [
37 jinja2
38 ply
39 six
40 packaging
41 ];
42
43 nativeCheckInputs = [
44 pytestCheckHook
45 mock
46 ];
47
48 pythonImportsCheck = [ "stone" ];
49
50 meta = with lib; {
51 description = "Official API Spec Language for Dropbox API V2";
52 homepage = "https://github.com/dropbox/stone";
53 changelog = "https://github.com/dropbox/stone/releases/tag/${src.tag}";
54 license = licenses.mit;
55 maintainers = [ ];
56 mainProgram = "stone";
57 };
58}