locan.data.metadata_utils.metadata_from_toml_string#

locan.data.metadata_utils.metadata_from_toml_string(toml_string)[source]#

Turn toml string into protobuf message instances.

Note

Parses Timestamp elements from string ā€˜2022-05-14T06:58:00Zā€™. Parses Duration elements from int in nanoseconds.

Parameters:

toml_string (Optional[str]) ā€“ TOML string with metadata.

Returns:

Message instances with name as declared in toml file.

Return type:

dict[str, google.protobuf.message.Message] | None