open-rmf/rmf_demos

unquoted string with colon seems to break python3-yaml on rhel8

cnboonhan opened this issue · 3 comments

I encounter an issue on certain distributions of python3-yaml ( such as the binary on rhel8 ) where this line is parsed weirdly:

https://github.com/open-rmf/rmf_demos/blob/main/rmf_demos_maps/maps/airport_terminal/airport_terminal.building.yaml#L29

Specifically, the colon in model: is confused as a key-value delimiter. Manually quoting the value seems to fix this.

oof. I'll have a look at this. It's interesting that a file generated by yaml-cpp is not parsing nicely on pyyaml. Hopefully there are some flags we can set in yaml-cpp that quote strings even when it's not strictly necessary.

This PR uses the yaml-cpp wrapper for PyYAML (CLoader and CDumper) for speed, but actually this might "fix" this issue as well. I'm curious, can you try this PR and see if the issue just goes away?
open-rmf/rmf_traffic_editor#394

its rather challenging to reproduce this now as the environment seems to be rather specific to the python version of 3.6. I suspect this will do the trick. Let's close this issue for now, I will try to reproduce it when the opportunity comes.