diff --git a/capella2polarion/connectors/polarion_worker.py b/capella2polarion/connectors/polarion_worker.py index 1c04fe65..ccadad1c 100644 --- a/capella2polarion/connectors/polarion_worker.py +++ b/capella2polarion/connectors/polarion_worker.py @@ -175,7 +175,10 @@ def compare_and_update_work_item( "Update work item %r for model element %s %r...", *log_args ) - old_checksums = {"__C2P__WORK_ITEM": old.get_current_checksum() or ""} + if not (old_checksum := old.get_current_checksum() or ""): + old_checksum = '{"__C2P__WORK_ITEM": ""}' + old_checksums = json.loads(old_checksum) + new_checksum = new.get_current_checksum() assert new_checksum is not None new_checksums = json.loads(new_checksum)