Repository navigation
Keep calendar gaps out of reported annual revenue growth - #6
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
An ordered, non-overlapping request can omit fiscal years or contain a calendar gap. The analyzer currently uses the previous listed period as the revenue-growth base anyway, producing a valid-looking annual growth figure from non-consecutive periods.
Use the earlier revenue only when that configured period ends exactly one day before the current period starts. Gaps keep the current-period facts and other metrics, but growth becomes
missing_inputforprevious_period_revenueand excludes the non-adjacent fact from its lineage. This supports adjacent 53/52-week calendars and does not infer years from labels. Document the explicit rule.Validation: 42 tests pass (3 calendar regressions added), Ruff lint/format and diff checks pass. A gapped report generates and verifies; skipped-year and renamed-label cases are covered. All nine committed demo files replay byte for byte and the preview check passes, so the default financial values and saved evidence are unchanged.