Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/parse_flexible_dates' into parse…
Browse files Browse the repository at this point in the history
…_flexible_dates
  • Loading branch information
bendichter committed Nov 23, 2023
2 parents 4b1ba61 + b08ed21 commit fd1a414
Showing 1 changed file with 3 additions and 8 deletions.
11 changes: 3 additions & 8 deletions parse.py
Original file line number Diff line number Diff line change
Expand Up @@ -773,15 +773,10 @@ def _handle_field(self, field):
conv[group] = partial(date_convert, dmy=n + 1, hms=n + 3, tz=n + 6)
self._group_index += 6
elif type == "tc":
s = r"(%s)\s+%s\s+(\d{1,2})\s+%s\s+(\d{4})" % (
DAYS_PAT,
MONTHS_PAT,
TIME_PAT,
)
s = r"(%s)\s+%s\s+(\d{1,2})\s+%s\s+(\d{4})"
s %= (DAYS_PAT, MONTHS_PAT, TIME_PAT)
n = self._group_index
conv[group] = partial(
date_convert, d_m_y=(n + 4, n + 3, n + 8), hms=n + 5
)
conv[group] = partial(date_convert, d_m_y=(n + 4, n + 3, n + 8), hms=n + 5)
self._group_index += 8
elif type == "tt":
s = r"%s?%s?%s?" % (TIME_PAT, AM_PAT, TZ_PAT)
Expand Down

0 comments on commit fd1a414

Please sign in to comment.