Skip to content
Snippets Groups Projects
Commit c74b290a authored by Alexander Schlemmer's avatar Alexander Schlemmer
Browse files

DOC: added docstring to describe_diff

parent 53d452c6
Branches
Tags
2 merge requests!159Release 0.16.o,!155Review filter lists and compare_entities
Pipeline #56218 passed with warnings
......@@ -527,6 +527,18 @@ def merge_entities(entity_a: Entity,
def describe_diff(olddiff, newdiff, name=None, as_update=True):
"""
This function generates a textual representation of the differences between two entities that have been generated
using compare_entities.
Arguments:
----------
olddiff: The diff output for the entity marked as "old".
newdiff: The diff output for the entity marked as "new".
Example:
>>> describe_diff(*compare_entities(db.Record().add_property("P"), "value", db.Record()))
"""
description = ""
for attr in list(set(list(olddiff.keys()) + list(newdiff.keys()))):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment