colcon / colcon-cargo

An extension for colcon-core to support Rust projects built with Cargo
http://colcon.readthedocs.io
Apache License 2.0
30 stars 20 forks source link

Do not assume a 'dependencies' section exists #26

Closed mxgrey closed 4 months ago

mxgrey commented 1 year ago

While most crates do have a dependencies section, it is possible for a crate to not have one at all. That would cause a KeyError for the current implementation. This PR instead attempts to get a dependencies section and then falls back on an empty dictionary if it did not exist.