calendaring_sync.objects.conflict module#
What the server has or said in a conflict, kept on its record until resolved.
- class calendaring_sync.objects.conflict.ConflictKind(*values)[source]#
Bases:
StrEnumHow the server’s copy and the local edit disagree.
- BOTH_CHANGED = 'both_changed'#
Both sides changed the object.
- REMOVED_REMOTELY = 'removed_remotely'#
The server removed the object, and you changed it.
- DELETED_LOCALLY = 'deleted_locally'#
You deleted the object, and the server changed it.
- BOTH_CREATED = 'both_created'#
The server has a new object at the id your unsent create chose.
- LOGICAL_KEY_TAKEN = 'logical_key_taken'#
The server refused your create, or your change, because another object holds its logical key. Once that object stops holding it, the edit is pending again.
- NOT_ALLOWED = 'not_allowed'#
The server won’t take your create, change or delete as you sent it, for example because you may only read the object, or because it won’t store such content. It stays open until you resolve it.
- class calendaring_sync.objects.conflict.Conflict(kind, remote_version, remote_fingerprint, remote_content, remote_containers, remote_logical_key, opened_at, holder=None, reason=None)[source]#
Bases:
objectWhat the server has or said about an object, kept where it conflicts with your edit.
For most conflicts that’s the server’s copy. For an edit the server refused, it holds no copy, only what the server said: the object holding the logical key, or its reason.
Together with its record’s synced copy and
Record.edit, it makes up the conflict record: the record’scontentis the object as both sides last agreed on it,edit.contentis yours, andremote_contentis the server’s. A resolution can compare all three, for example to keep both sides where they changed different parts of the object.- kind#
How the two sides disagree.
- Type:
- remote_version#
The version of the server’s copy,
Noneif it has none, the server removed the object, or after a fingerprint scheme change until the server’s copy is fetched again.
- remote_fingerprint#
The fingerprint of the server’s copy,
Noneif the server removed the object, or after a fingerprint scheme change until the server’s copy is fetched again.
- remote_containers#
The containers of the server’s copy.
- remote_logical_key#
The logical key of the server’s copy, if it has one.
- holder#
For an edit refused because another object holds its logical key, that object’s object id when the server named it;
Noneotherwise.