forked from solderpunk/AV-98
fixes a crash when parsing invalid RSS dates
This commit is contained in:
parent
bf17b21b30
commit
856b89ff45
|
@ -17,6 +17,7 @@ Changes since beta1
|
|||
- fixes a bug in HTML renderer where some hX element were not closed properly
|
||||
- fixes input in Gemini while online
|
||||
- fixes a crash with invalid URL
|
||||
- fixes a crash while parsing invalid dates in RSS
|
||||
- fixes hang/crash when meeting the ";" itemtype in gopher
|
||||
- attempt at hiding XMLparsedAsHTMLWarning from BS4 library
|
||||
- chafa now used by default everywhere if version > 1.10
|
||||
|
|
|
@ -903,8 +903,12 @@ class FeedRenderer(GemtextRenderer):
|
|||
else:
|
||||
line = "* "
|
||||
if "published" in i:
|
||||
pub_date = time.strftime("%Y-%m-%d",i.published_parsed)
|
||||
line += pub_date + " : "
|
||||
#sometimes fails so protect it
|
||||
try:
|
||||
pub_date = time.strftime("%Y-%m-%d",i.published_parsed)
|
||||
line += pub_date + " : "
|
||||
except:
|
||||
pass
|
||||
if "title" in i:
|
||||
line += "%s" %(i.title)
|
||||
if "author" in i:
|
||||
|
|
Loading…
Reference in New Issue