PyCQA / baron

IDE allow you to refactor code, Baron allows you to write refactoring code.
http://baron.pycqa.org
GNU Lesser General Public License v3.0
289 stars 50 forks source link

When rendering, skip missing keys #168

Open xloem opened 3 years ago

xloem commented 3 years ago

This is a very quick change to provide for rendering structures that are missing nonimportant keys. It simply skips them.

A change to provide default values for keys might be more thorough; unsure.

>>> baron.dumps([dict(type='print', value=[dict(type='associative_parenthesis', value=dict(type='string', value='"hello, world"'))])])
'print("hello, world")'