release: reject inverted reader windows and clarify diagnostics - #180
Merged
Conversation
Keep #180's until-relative compare defaults exactly once. The #182 reader expansion carried an older duplicate declaration block whose now-relative defaults would both fail function compilation and discard the B5 contract. Use #189's _raw_retention_start() and _active_slots() helpers for #180's alternate-coverage NOTICE instead of reintroducing the pre-B3 retention formula. This keeps the corrected logical/physical raw boundary split and excluded-slot rule intact. Adapt the sparse-hour C1 gate to #182's honest rollup_1h_flat plan: aggregate readers disclose one widened hourly datum, while report still returns silent NULL because exact per-minute coverage is not derivable.
When cron.database_name is unset or names the current database, explain how to configure pg_cron or use the external scheduler. Recommend installing pg_ash in another database only when the setting names a real, different target. Document ash.report's rollup_1m-only contract in the README and guard both disclosures in CI. Exercise mutable cron.database_name placeholders only on the cron-off axis because preloaded pg_cron registers the GUC as postmaster-only. This closes the Codex pre-merge review findings without changing report behavior.
NikolayS
commented
Jul 27, 2026
NikolayS
left a comment
Owner
Author
There was a problem hiding this comment.
Pre-merge review — PASS
Codex review is standing in for REV for this merge.
Audit verdict verified: B5 requires an error for since > until, an until-only default of until - interval '1 hour', and preservation of the #63 overflow/degenerate clamp after validation. N3–N7 and C1 Option A are documentation/diagnostic contracts, not report source changes.
RED / GREEN
- RED on current main
c28fce3:aas,timeline,top,report,chart,samples,summary, and bothcomparewindows accepted explicit inversions; until-only calls used the wrong now-relative window. - GREEN on
56b67dd: all exact function-specific errors and until-relative bounds pass, including both compare windows and the #63 edge clamps. ash.report()still returns SQL NULL whenrollup_1mis absent. Raw-only and valid hourly-only windows produce exactly one source-naming NOTICE; no-source, excluded-slot-only, and invalid sparse-hour cases remain silent.
Hand-rebase checks
- Kept #181's dynamic reader/helper grant bundle and
_admin_funcsnarrowing; #180 adds no helper, and all reader-visible dependencies remain covered. - Kept #182's numeric bucket rounding and honest
rollup_1h_flatplan for incompleteminute_counts. - Replaced the pre-B3 raw formula with #189's
_raw_retention_start()and_active_slots(), preserving the logical/physical boundary and excluded-slot rule. - Removed the duplicate pre-rebase
ash.comparedeclaration block.
Review findings resolved
- README lacked the explicit
rollup_1m-only report contract. Added the shipped disclosure and CI guards. - The pg_cron hint could recommend
install pg_ash in (not set)or recommend another database when the configured target was the current database. Split unset/current/alternate guidance and behaviorally tested each branch. - The first test fix tried to mutate preloaded pg_cron's postmaster-only
cron.database_nameGUC. Restricted mutable placeholder probes to the cron-off axis and verified a real pg_cron-preloaded PG17 server afterDROP EXTENSIONdoes not attempt mutation.
Final Codex re-review: no actionable regressions found. Isolated PG17 runtime gates, fresh install, YAML parse, documentation guards, and git diff --check all pass. Scratch resources were removed.
NikolayS
marked this pull request as ready for review
July 27, 2026 21:45
samo-agent
added a commit
to samo-agent/pg_ash
that referenced
this pull request
Jul 27, 2026
Document that retained AAS is weighted by the current sampler interval, successful idle ticks are not persisted, and intervals above one minute can overstate minute extrema. Mark the affected user stories partial and expose the limitation in the README, release notes, blueprints, and sample_interval catalog comment. Hand-resolve against current main by retaining NikolayS#182's final grain/provenance contracts, NikolayS#180's until-only window and report disclosures, NikolayS#189's raw-boundary wording, and NikolayS#187's retired-benchmark caveat.
This was referenced Jul 27, 2026
NikolayS
added a commit
that referenced
this pull request
Jul 27, 2026
Document that retained AAS is weighted by the current sampler interval, successful idle ticks are not persisted, and intervals above one minute can overstate minute extrema. Mark the affected user stories partial and expose the limitation in the README, release notes, blueprints, and sample_interval catalog comment. Hand-resolve against current main by retaining #182's final grain/provenance contracts, #180's until-only window and report disclosures, #189's raw-boundary wording, and #187's retired-benchmark caveat. Co-authored-by: samo-agent <280144521+samo-agent@users.noreply.github.com>
This was referenced Aug 21, 2026
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.
Summary
ash.aas,timeline,top,report,chart,samples,summary, and bothcomparewindows; anchor anuntil-only call to the preceding hour while retaining the bug: _at readers raise 'integer out of range' on absurd timestamps — same class as #51 #63 overflow/degenerate clamp. Closes Release blocker: until-only reader calls answer the wrong window #165.rollup_1m-only report contract in the catalog and README and emit a NOTICE naming raw orrollup_1halternate coverage without changing the SQL NULL return behavior. This implements C1 Option A. Closes Docs: disclose ash.report()'s rollup_1m-only coverage dependency #172; refs Decision request: define ash.report coverage and sub-day rotation contracts #167.Rebase resolution
Hand-rebased onto main
c28fce3. The resolution preserves #181's dynamic reader/helper grants, #182's honestrollup_1h_flatplanning, and #189's logical/physical raw-retention boundary and active-slot exclusion. No new reader helper was introduced.Validation
ash.report()remains SQL NULL; uncovered and sparse invalid-hour windows remain silent.git diff --checkpass.