nixpkgs/pkgs/development/python-modules/gym/default.nix
Samuel Ainsworth b708a3523a
python3Packages.gym: remove unnecessary string interpolation (#208846)
* python3Packages.gym: remove unnecessary string interpolation

* python3Packages.gym: use "refs/tags/foo" instead of "foo"

Co-authored-by: Martin Weinelt <mweinelt@users.noreply.github.com>

Co-authored-by: Martin Weinelt <mweinelt@users.noreply.github.com>
2023-01-03 16:30:06 -05:00

40 lines
846 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, numpy
, cloudpickle
, gym-notices
, importlib-metadata
, pythonOlder
}:
buildPythonPackage rec {
pname = "gym";
version = "0.26.2";
src = fetchFromGitHub {
owner = "openai";
repo = pname;
rev = "refs/tags/${version}";
sha256 = "sha256-uJgm8l1SxIRC5PV6BIH/ht/1ucGT5UaUhkFMdusejgA=";
};
propagatedBuildInputs = [
cloudpickle
numpy
gym-notices
] ++ lib.optionals (pythonOlder "3.10") [ importlib-metadata ];
# The test needs MuJoCo that is not free library.
doCheck = false;
pythonImportsCheck = [ "gym" ];
meta = with lib; {
description = "A toolkit for developing and comparing your reinforcement learning agents";
homepage = "https://gym.openai.com/";
license = licenses.mit;
maintainers = with maintainers; [ hyphon81 ];
};
}