1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 setuptools, 6 pytestCheckHook, 7}: 8 9buildPythonPackage rec { 10 pname = "json-repair"; 11 version = "0.51.0"; 12 pyproject = true; 13 14 src = fetchFromGitHub { 15 owner = "mangiucugna"; 16 repo = "json_repair"; 17 tag = "v${version}"; 18 hash = "sha256-XXbJwzvt2gQox1+vQsJ3ajVoFlJVG/z2eUECQkWOi64="; 19 }; 20 21 build-system = [ setuptools ]; 22 23 nativeCheckInputs = [ pytestCheckHook ]; 24 25 disabledTestPaths = [ 26 "tests/test_performance.py" 27 ]; 28 29 pythonImportsCheck = [ "json_repair" ]; 30 31 meta = with lib; { 32 description = "Module to repair invalid JSON, commonly used to parse the output of LLMs"; 33 homepage = "https://github.com/mangiucugna/json_repair/"; 34 changelog = "https://github.com/mangiucugna/json_repair/releases/tag/${src.tag}"; 35 license = licenses.mit; 36 maintainers = with maintainers; [ greg ]; 37 }; 38}