Skip to content

Commit 8f4553d

Browse files
author
Dominick Leppich
committed
fix: log intentional deletion
1 parent 1bdf2eb commit 8f4553d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

migration/lib/mets_manipulator.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,9 @@ def process_vocabulary_reference_by_value(self, node):
253253
except Exception as e:
254254
# If this fails as well and the value is not found, remove the metadata if configured
255255
if 'has no results' in e.__str__() and self.ctx.is_removable_metadata(vocabulary_id, node.text):
256-
logging.warn(f'Removing node due to intentionally missing vocabulary value: "{node.text}"')
256+
warn_message = f'Removing node due to intentionally missing vocabulary value: "{node.text}"'
257+
logging.warn(warn_message)
258+
self.ctx.log_issue(self.file_path, warn_message)
257259
self.remove_metadata_node(node)
258260
else:
259261
error = f'Unable to find record by value: {value}\n\t\t{e}'

0 commit comments

Comments
 (0)