Skip to content

feat: preserve custom rolling lookback ranges - #37

Merged
meaningforger merged 1 commit into
mainfrom
codex/custom-calendar-rolling-filter
Oct 9, 2026
Merged

meaningforger merged 1 commit into
mainfrom
codex/custom-calendar-rolling-filter

Conversation

@meaningforger

Copy link
Copy Markdown
Contributor

Summary

  • support time-range filters on custom-calendar rolling windows without Gregorian date shifting
  • keep the visible range as a post-evaluation predicate while retaining the safe source upper bound
  • add a result oracle proving prior fiscal periods remain in the rolling calculation across DuckDB, Doris, and ClickHouse
  • replace the former explicit-rejection contract and document the supported semantics

Correctness example

For a three-fiscal-week window filtered to 2026-01-19 through 2026-01-26, the 2026-01-19 result remains 40 because the 2026-01-05 value is retained for calculation. Applying the lower bound before window evaluation would incorrectly return 30.

Validation

  • make check
  • make test-duckdb-backend
  • go test -p 4 ./...
  • make fmt-check docs-check
  • git diff --check

@meaningforger
meaningforger merged commit 7b0fafe into main Oct 9, 2026
8 checks passed
@meaningforger
meaningforger deleted the codex/custom-calendar-rolling-filter branch October 9, 2026 15:41
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