159e378cbb
GitOrigin-RevId: c04d5652cfa9742b1d519688f65d1bbccea9eb7e
36 lines
886 B
Nix
36 lines
886 B
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
setuptools,
|
|
pytestCheckHook,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "json-repair";
|
|
version = "0.27.2";
|
|
pyproject = true;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "mangiucugna";
|
|
repo = "json_repair";
|
|
rev = "refs/tags/${version}";
|
|
hash = "sha256-NYY76sIp4XirVifOPOs6iEzP93ERzNIHAvpgU4+fi24=";
|
|
};
|
|
|
|
build-system = [ setuptools ];
|
|
|
|
nativeBuildInputs = [ pytestCheckHook ];
|
|
|
|
disabledTestPaths = [ "tests/test_performance.py" ];
|
|
|
|
pythonImportsCheck = [ "json_repair" ];
|
|
|
|
meta = with lib; {
|
|
description = "Module to repair invalid JSON, commonly used to parse the output of LLMs";
|
|
homepage = "https://github.com/mangiucugna/json_repair/";
|
|
changelog = "https://github.com/mangiucugna/json_repair/releases/tag/${version}";
|
|
license = licenses.mit;
|
|
maintainers = with maintainers; [ greg ];
|
|
};
|
|
}
|