Skip to content

Conversation

@77Torpedo77
Copy link

This PR fixes a crash (TypeError: sequence item 7: expected str instance, NoneType found) that occurs when self.tex.values() contains None values during tldr and affiliations extraction.

Changes

  1. Filter None values: Modified the join logic to explicitly filter out None values and convert items to strings before joining ([str(v) for v in self.tex.values() if v is not None]).
  2. Enhanced Logging: Added debug logs to handle cases where the extracted content is empty or stripped, aiding in future debugging.

Related Issue / Error Log

Fixes the following traceback:

TypeError: sequence item 7: expected str instance, NoneType found
  File "/home/runner/work/zotero-arxiv-daily/zotero-arxiv-daily/paper.py", line 221, in affiliations
    content = "\n".join(self.tex.values())

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant