Skip to content

Commit

Permalink
fix: Change non-current year error to a warning (#1109)
Browse files Browse the repository at this point in the history
Fixes #704
  • Loading branch information
kesara authored Mar 11, 2024
1 parent a809924 commit f58e052
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xml2rfc/writers/preptool.py
Original file line number Diff line number Diff line change
Expand Up @@ -650,7 +650,7 @@ def front_insert_date(self, e, p):
year = str(today.year)
if not month:
if year != str(today.year):
self.die(e, "Expected <date> to have the current year when month is missing, but found '%s'" % (d.get('year')))
self.warn(e, "Expected <date> to have the current year when month is missing, but found '%s'" % (d.get('year')))
month = today.strftime('%m')
day = today.strftime('%d')
datestr = "%s-%s-%s" %(year, month, day or '01')
Expand Down

0 comments on commit f58e052

Please sign in to comment.