Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 fetchPypi, 4 buildPythonPackage, 5 pythonAtLeast, 6 setuptools, 7 tzlocal, 8 six, 9 pyjsparser, 10}: 11 12buildPythonPackage rec { 13 pname = "js2py"; 14 version = "0.74"; 15 pyproject = true; 16 17 # broken with Python 3.12 18 # https://github.com/PiotrDabkowski/Js2Py/issues/317 19 disabled = pythonAtLeast "3.12"; 20 21 src = fetchPypi { 22 pname = "Js2Py"; 23 inherit version; 24 hash = "sha256-OfOmqoRpGA77o8hncnHfJ8MTMv0bRx3xryr1i4e4ly8="; 25 }; 26 27 nativeBuildInputs = [ setuptools ]; 28 29 propagatedBuildInputs = [ 30 pyjsparser 31 six 32 tzlocal 33 ]; 34 35 # Test require network connection 36 doCheck = false; 37 38 pythonImportsCheck = [ "js2py" ]; 39 40 meta = with lib; { 41 description = "JavaScript to Python Translator & JavaScript interpreter written in 100% pure Python"; 42 homepage = "https://github.com/PiotrDabkowski/Js2Py"; 43 license = licenses.mit; 44 maintainers = with maintainers; [ onny ]; 45 }; 46}