mirror of
https://github.com/saymrwulf/stable-baselines3.git
synced 2026-05-22 22:10:16 +00:00
* `dummy_vec_env` fix `seed()` causing a reset * rename `seed` * fixes * bug fix * fix seed return type * Cleanup seeding, add test and remove compat wrapper * Update env checker and tests * Add deterministic test for make_vec_env --------- Co-authored-by: Antonin Raffin <antonin.raffin@ensta.org>
83 lines
2.2 KiB
TOML
83 lines
2.2 KiB
TOML
[tool.ruff]
|
|
# Same as Black.
|
|
line-length = 127
|
|
# Assume Python 3.7
|
|
target-version = "py37"
|
|
# See https://beta.ruff.rs/docs/rules/
|
|
select = ["E", "F", "B", "UP", "C90", "RUF"]
|
|
# Ignore explicit stacklevel`
|
|
ignore = ["B028"]
|
|
|
|
[tool.ruff.per-file-ignores]
|
|
# Default implementation in abstract methods
|
|
"./stable_baselines3/common/callbacks.py"= ["B027"]
|
|
"./stable_baselines3/common/noise.py"= ["B027"]
|
|
|
|
|
|
[tool.ruff.mccabe]
|
|
# Unlike Flake8, default to a complexity level of 10.
|
|
max-complexity = 15
|
|
|
|
[tool.black]
|
|
line-length = 127
|
|
|
|
[tool.isort]
|
|
profile = "black"
|
|
line_length = 127
|
|
src_paths = ["stable_baselines3"]
|
|
|
|
[tool.pytype]
|
|
inputs = ["stable_baselines3"]
|
|
disable = ["pyi-error"]
|
|
|
|
[tool.mypy]
|
|
ignore_missing_imports = true
|
|
follow_imports = "silent"
|
|
show_error_codes = true
|
|
exclude = """(?x)(
|
|
stable_baselines3/common/buffers.py$
|
|
| stable_baselines3/common/callbacks.py$
|
|
| stable_baselines3/common/distributions.py$
|
|
| stable_baselines3/common/off_policy_algorithm.py$
|
|
| stable_baselines3/common/policies.py$
|
|
| stable_baselines3/common/save_util.py$
|
|
| stable_baselines3/common/utils.py$
|
|
| stable_baselines3/common/vec_env/__init__.py$
|
|
| stable_baselines3/common/vec_env/vec_normalize.py$
|
|
| stable_baselines3/common/vec_env/vec_transpose.py$
|
|
| stable_baselines3/common/vec_env/vec_video_recorder.py$
|
|
| stable_baselines3/her/her_replay_buffer.py$
|
|
| tests/test_logger.py$
|
|
| tests/test_train_eval_mode.py$
|
|
)"""
|
|
|
|
[tool.pytest.ini_options]
|
|
# Deterministic ordering for tests; useful for pytest-xdist.
|
|
env = [
|
|
"PYTHONHASHSEED=0"
|
|
]
|
|
|
|
filterwarnings = [
|
|
# Tensorboard warnings
|
|
"ignore::DeprecationWarning:tensorboard",
|
|
# Gymnasium warnings
|
|
"ignore::UserWarning:gymnasium",
|
|
]
|
|
markers = [
|
|
"expensive: marks tests as expensive (deselect with '-m \"not expensive\"')"
|
|
]
|
|
|
|
[tool.coverage.run]
|
|
disable_warnings = ["couldnt-parse"]
|
|
branch = false
|
|
omit = [
|
|
"tests/*",
|
|
"setup.py",
|
|
# Require graphical interface
|
|
"stable_baselines3/common/results_plotter.py",
|
|
# Require ffmpeg
|
|
"stable_baselines3/common/vec_env/vec_video_recorder.py",
|
|
]
|
|
|
|
[tool.coverage.report]
|
|
exclude_lines = [ "pragma: no cover", "raise NotImplementedError()", "if typing.TYPE_CHECKING:"]
|