depot/third_party/nixpkgs/pkgs/development/python-modules/json-repair/default.nix
Default email 159e378cbb Project import generated by Copybara.
GitOrigin-RevId: c04d5652cfa9742b1d519688f65d1bbccea9eb7e
2024-09-19 17:19:46 +03:00

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 ];
};
}