Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suppress TraCI Error on simulationStep #1770

Merged
merged 2 commits into from
Dec 14, 2022
Merged

Conversation

saulfield
Copy link
Contributor

As mentioned in #1751 (comment) and #1155, SUMO versions after 1.10.0 throw an error in the first call to simulationStep() after calling vehicle.remove(). After investigating this, I couldn't find a cause for the error, and it did not seem to impact the simulation, so I am suppressing the error message.

For future reference, this error can be reproduced reliably by running:

scl run examples/egoless.py scenarios/sumo/loop/ --headless --episodes=1

Comment on lines +472 to +473
with suppress_output(stderr=False):
self._traci_conn.simulationStep(self._cumulative_sim_seconds)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is sumo outputting errors on stdout for some reason?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this error is coming through stdout.

Copy link
Collaborator

@Gamenot Gamenot Dec 8, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Weird. I suppose they consider that it is not crashing. Perhaps it is just reasonable to not output the sumo stdout logs because we have it set to log to a file anyway.

@saulfield saulfield merged commit 44012d8 into develop Dec 14, 2022
@saulfield saulfield deleted the saul/suppress-traci-error branch December 14, 2022 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants