From dabfbfc440c9fc9f615fbeee192860206366df3d Mon Sep 17 00:00:00 2001 From: simonsays1980 Date: Mon, 13 Oct 2025 16:57:11 +0200 Subject: [PATCH] Fixed a small bug in type hints of the 'learner_connector'. Signed-off-by: simonsays1980 --- rllib/algorithms/algorithm_config.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rllib/algorithms/algorithm_config.py b/rllib/algorithms/algorithm_config.py index d6a62fc0af3b..9d6172b4c94e 100644 --- a/rllib/algorithms/algorithm_config.py +++ b/rllib/algorithms/algorithm_config.py @@ -2354,7 +2354,10 @@ def training( # Moved to `learners()` method. learner_class: Optional[Type["Learner"]] = NotProvided, learner_connector: Optional[ - Callable[["RLModule"], Union["ConnectorV2", List["ConnectorV2"]]] + Callable[ + [gym.spaces.Space, gym.spaces.Space], + Union["ConnectorV2", List["ConnectorV2"]], + ] ] = NotProvided, add_default_connectors_to_learner_pipeline: Optional[bool] = NotProvided, learner_config_dict: Optional[Dict[str, Any]] = NotProvided,