commit 7138915c608f61334c228a0cfe1b5030d552a729 from: Aleksey Ryndin date: Tue Jan 28 12:03:28 2025 UTC Fix python3.9 (TypeError: unsupported operand type(s) for |: 'type' and 'NoneType') commit - fb759b68996869f33e1cec014d71cd00ddc42315 commit + 7138915c608f61334c228a0cfe1b5030d552a729 blob - 07de600cef1137979d6c30b1dc55a8e5739dcde7 blob + dc4cb5a897dcbfe0bb9be8b8d846c66bbe0e6824 --- katasterismos.py +++ katasterismos.py @@ -15,7 +15,7 @@ uses_netloc.append("gemini") @dataclass() class Feed: url: str - title: str | None = None + title: str @dataclass() @@ -70,7 +70,7 @@ def get(url): def parse_feed(url, body, feeds): - _feed = Feed(url=url) + _feed = Feed(url=url, title="") for line in body.splitlines(): if line.startswith("#") and line[1:2] != "#" and not _feed.title: _feed.title = line[1:].strip()