Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 fetchFromGitHub, 4 fetchpatch2, 5 buildPythonPackage, 6 setuptools, 7 pythonOlder, 8 # Python deps 9 uplc, 10 graphlib-backport, 11 ordered-set, 12}: 13 14buildPythonPackage rec { 15 pname = "pluthon"; 16 version = "0.5.3"; 17 18 format = "pyproject"; 19 20 src = fetchFromGitHub { 21 owner = "OpShin"; 22 repo = "pluthon"; 23 rev = version; 24 hash = "sha256-pX/XPZJQZaSY06nLLEvhf+1LEqYG3CdgPV/3Q6XOzTs="; 25 }; 26 27 patches = [ 28 (fetchpatch2 { 29 name = "pluthon-bump-uplc.patch"; 30 # https://github.com/OpShin/pluthon/pull/21 31 url = "https://github.com/OpShin/pluthon/commit/4b0a40223f253643056cab12231264c5beffc666.patch?full_index=1"; 32 hash = "sha256-dO9JaIpkugZFKsr3Hd0cFCy7K+cmf77UfrdkZ+sGQtA="; 33 }) 34 ]; 35 36 propagatedBuildInputs = [ 37 setuptools 38 uplc 39 ordered-set 40 ] ++ lib.optional (pythonOlder "3.9") graphlib-backport; 41 42 pythonImportsCheck = [ "pluthon" ]; 43 44 meta = with lib; { 45 description = "Pluto-like programming language for Cardano Smart Contracts in Python"; 46 homepage = "https://github.com/OpShin/pluthon"; 47 license = licenses.mit; 48 maintainers = with maintainers; [ t4ccer ]; 49 }; 50}