diff --git a/smarts/core/sumo_traffic_simulation.py b/smarts/core/sumo_traffic_simulation.py index 9212a5aecd..63305debb2 100644 --- a/smarts/core/sumo_traffic_simulation.py +++ b/smarts/core/sumo_traffic_simulation.py @@ -466,7 +466,11 @@ def _step(self, dt): # we tell SUMO to step through dt more seconds of the simulation self._cumulative_sim_seconds += dt try: - self._traci_conn.simulationStep(self._cumulative_sim_seconds) + # Suppress errors here, to avoid a known (and likely benign) + # error related to removing vehicles. + # See: https://github.com/huawei-noah/SMARTS/issues/1155 + with suppress_output(stderr=False): + self._traci_conn.simulationStep(self._cumulative_sim_seconds) except self._traci_exceptions as e: self._handle_traci_disconnect(e) return ProviderState()