Skip to content

Commit

Permalink
Make sure logging message is type safe.
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathangreen committed Sep 22, 2023
1 parent 74988cd commit d6cc2d0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion core/opds_import.py
Original file line number Diff line number Diff line change
Expand Up @@ -512,9 +512,10 @@ def import_from_feed(
if work:
works[key] = work
except Exception as e:
collection_name = self.collection.name if self.collection else "None"
logging.warning(
f"Non-fatal exception: Failed to import item - import will continue: "
f"identifier={key}; collection={self.collection.name}; "
f"identifier={key}; collection={collection_name}/{self._collection_id}; "
f"data_source={self.data_source}; exception={e}",
stack_info=True,
)
Expand Down

0 comments on commit d6cc2d0

Please sign in to comment.