lol

python310Packages.stone: replace inspect.getargspec

+22 -12
+22 -12
pkgs/development/python-modules/stone/default.nix
··· 5 5 , ply 6 6 , pytestCheckHook 7 7 , six 8 + , pythonOlder 8 9 }: 9 10 10 11 buildPythonPackage rec { 11 12 pname = "stone"; 12 13 version = "3.3.1"; 14 + format = "setuptools"; 13 15 14 - # pypi sdist misses requirements.txt 16 + disabled = pythonOlder "3.7"; 17 + 15 18 src = fetchFromGitHub { 16 19 owner = "dropbox"; 17 20 repo = pname; 18 - rev = "v${version}"; 21 + rev = "refs/tags/v${version}"; 19 22 hash = "sha256-0FWdYbv+paVU3Wj6g9OrSNUB0pH8fLwTkhVIBPeFB/U="; 20 23 }; 21 24 22 25 postPatch = '' 23 - sed -i '/pytest-runner/d' setup.py 26 + # https://github.com/dropbox/stone/issues/288 27 + substituteInPlace stone/frontend/ir_generator.py \ 28 + --replace "inspect.getargspec" "inspect.getfullargspec" 29 + substituteInPlace setup.py \ 30 + --replace "'pytest-runner == 5.2.0'," "" 24 31 ''; 25 32 26 - propagatedBuildInputs = [ ply six ]; 27 - 28 - nativeCheckInputs = [ pytestCheckHook mock ]; 33 + propagatedBuildInputs = [ 34 + ply 35 + six 36 + ]; 29 37 30 - # try to import from `test` directory, which is exported by the python interpreter 31 - # and cannot be overridden without removing some py3 to py2 support 32 - disabledTestPaths = [ 33 - "test/test_tsd_types.py" 34 - "test/test_js_client.py" 38 + nativeCheckInputs = [ 39 + pytestCheckHook 40 + mock 35 41 ]; 42 + 36 43 disabledTests = [ 37 44 "test_type_name_with_module" 38 45 ]; 39 46 40 - pythonImportsCheck = [ "stone" ]; 47 + pythonImportsCheck = [ 48 + "stone" 49 + ]; 41 50 42 51 meta = with lib; { 43 52 description = "Official Api Spec Language for Dropbox"; 44 53 homepage = "https://github.com/dropbox/stone"; 54 + changelog = "https://github.com/dropbox/stone/releases/tag/v${version}"; 45 55 license = licenses.mit; 46 56 maintainers = with maintainers; [ jonringer ]; 47 57 };