Skip to content

Support parsing time ranges - #59

Merged
aldroid1 merged 5 commits into
mainfrom
feature/range-support
Jul 23, 2026
Merged

Support parsing time ranges#59
aldroid1 merged 5 commits into
mainfrom
feature/range-support

Conversation

@aldroid1

Copy link
Copy Markdown
Owner
  • Adding to_range() to parse date ranges such as last 2 weeks or last month into start and end timestamps. Start time is inclusive, end time exclusive.

  • The implementation is quite simple for now, and limited to single recognized pattern rather than processing all recognized fragments. Latter would be plausible after we can identify the boundaries between two dates with some patterns - e.g. between ... and ...

  • With dates, prev/last have been interchangeable used to mean the last full period of time, while past refers to the period of time since current timetamp. E.g. last week for previous week while past week for past 7 days. This might not be so clear cut for ranges, so simply deferring implementing past for them.

@aldroid1
aldroid1 merged commit cf0d626 into main Jul 23, 2026
18 checks passed
@aldroid1
aldroid1 deleted the feature/range-support branch July 23, 2026 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant