e2nIEE / pandahub

A data hub for pandapower and pandapipes networks based on MongoDB.
Other
12 stars 12 forks source link

Return changed elements on add/update/delete #18

Closed jthurner closed 1 year ago

jthurner commented 1 year ago

create_element_in_db and delete_net_element return the created/deleted document set_net_value_in_db returns a dictionary {"document": changed_doc, changed_field : {"current": new value, "previous": old value}

Possible breaking changes: delete_net_element and set_net_value_in_db did not return anything before. create_element_in_db previously returned pymongos' InsertOneResult and now returns the created document.