From 1b6078d801b71e39e40a7cf911e33824c7277886 Mon Sep 17 00:00:00 2001 From: Mick van Gelderen Date: Tue, 10 Dec 2024 05:18:10 -0800 Subject: [PATCH] Treat warnings as errors (#41) Treat warnings as errors in pytests. --- pyproject.toml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index daf68a5..29fefe7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,6 +11,15 @@ build-backend = "hatchling.build" [tool.hatch.build] include = ["flashbax/*"] +[tool.pytest.ini_options] +filterwarnings = [ + "error", + "ignore:`sample_sequence_length` greater than `min_length_time_axis`:UserWarning:flashbax", + "ignore:Setting period greater than sample_sequence_length will result in no overlap betweentrajectories:UserWarning:flashbax", + "ignore:Setting max_size dynamically sets the `max_length_time_axis` to be `max_size`//`add_batch_size = .*`:UserWarning:flashbax", + "ignore:jax.tree_map is deprecated:DeprecationWarning:flashbax", +] + [project] name = "flashbax" description = "Flashbax is an experience replay library oriented around JAX. Tailored to integrate seamlessly with JAX's Just-In-Time (JIT) compilation."