<@U020J2W6Q84>: After installing openlane 2 and ru...
# openlane-2
d
@donn: After installing openlane 2 and running the spm example I have a config.yaml file in my spm dir but no config.tcl, as shown in your tutorial. Below shows the contents of my spm tutorial. 1. What is the difference between .json and .yaml config files? 2. Is this an issue that I have a config.yaml instead of config.json? Thanks,
d
Ah, the tutorial is out of date- we switched to YAML a while back. No, they're semantically identical, YAML is just prettier.
d
Cool. Thanks for clarifying Mohamed.
@donn: One difference between .json and .yaml is I can insert comments in a .yaml while I cant in .json. This is a nice feature so I would like to just .yaml files. I have a flow running with a config.json file containing the below line: "DIE_AREA": "0 0 300 300", I changed this to the below in my config.yaml file: DIE_AREA: 0 0 300 300 However, the tool errors out due to: ERROR Refusing to automatically convert string at 'DIE_AREA' to list How do I make this conversion? Thanks
d
Declare it as a list: [0, 0, 300, 300]
OpenLane 2 is pretty strongly typed, JSON and Tcl files though do try their best to convert things so backwards compatibility with OpenLane 1 is maintained. Because YAML was never supported by OpenLane 1, it is type-strict by default.
(incidentally, you can opt into type-strictness in JSON by setting
"meta": { "version": 2 }
or opt out of it in YAML by setting
meta: { "version": 2 }
)
d
Thanks @donn. That works now. So the top level config can be written as a .json or .yaml file in openlane2 but only .json in openlane1. Even tho the top level can be specified as .yaml I see the sub-directories still all use .json files. Understanding things better now! Cheers