Files
nixpkgs/pkgs/development/python-modules/mjviser/default.nix
Guilhem Saurel fca10e6434 python3Packages.mjviser: init at 0.0.14
Co-authored-by: Gaétan Lepage <gaetan@glepage.com>
2026-09-16 15:12:11 +02:00

65 lines
1.0 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
# build-system
uv-build,
# dependencies
mujoco,
numpy,
pillow,
trimesh,
viser,
# tests
pytestCheckHook,
}:
buildPythonPackage (finalAttrs: {
pname = "mjviser";
version = "0.0.14";
pyproject = true;
__structuredAttrs = true;
src = fetchFromGitHub {
owner = "mujocolab";
repo = "mjviser";
tag = "v${finalAttrs.version}";
hash = "sha256-LzltAgWKK84gQU4IlzKv7SClaUrLCdyU8vzHh4LIqDs=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail \
"uv_build>=0.8.19,<0.9.0" \
"uv_build"
'';
build-system = [
uv-build
];
dependencies = [
mujoco
numpy
pillow
trimesh
viser
];
pythonImportsCheck = [ "mjviser" ];
nativeCheckInputs = [
pytestCheckHook
];
meta = {
description = "Web-based MuJoCo viewer powered by Viser";
homepage = "https://github.com/mujocolab/mjviser";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ nim65s ];
};
})