Showing warning about date format

main
Bob Mottram 2021-09-07 20:33:27 +01:00
parent a1901609bf
commit a8ac86b758
1 changed files with 2 additions and 2 deletions

View File

@ -220,8 +220,6 @@ def parseFeedDate(pubDate: str) -> str:
publishedDate = \
datetime.strptime(pubDate, dateFormat)
except BaseException:
print('WARN: unrecognized date format: ' +
pubDate + ' ' + dateFormat)
continue
if publishedDate:
@ -240,6 +238,8 @@ def parseFeedDate(pubDate: str) -> str:
pubDateStr = str(publishedDate)
if not pubDateStr.endswith('+00:00'):
pubDateStr += '+00:00'
else:
print('WARN: unrecognized date format: ' + pubDate)
return pubDateStr