docs(adr): compress to 3 records in the domain-modeling format - #81
Merged
Merged
Conversation
Rewrite each surviving record as a single paragraph, dropping the **Decision:** line, the ## Context / ## Decision & rationale headings and the **Revisit trigger:** section. Dropped: 0002-keep-construction-factories - keeping two single-caller constructor-bundling factories is trivially reversible and was not a real trade-off, so it fails the admission test. Its rule, that the package mirrors FastStream's own Redis broker layout, is folded into the new 0002. Renumbered: 0003-no-per-call-middlewares-kwarg -> 0002, 0004-typing-extensions-over-version-gated-imports -> 0003. No merges.
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.
Rewrites
docs/adr/from 4 records (~1,460 words) to 3 (~470 words), one paragraph each, in theshape the domain-modeling ADR format asks for. The
**Decision:**line, the## Contextand## Decision & rationaleheadings and the**Revisit trigger:**section are gone; a revisittrigger survives only where it is the real boundary of the decision. Survivors keep their original
relative order and are renumbered 0001-0003.
Evaluation
Each record was tested against the admission test: hard to reverse, surprising without context, the
result of a real trade-off. A record that fails on its own but states a rule a survivor relies on
was folded into that survivor as a sentence.
_patch_brokermocking the Redis client will propose the in-memory store that was already rejected.middlewares=kwargtyping_extensionsimport that looks redundant on 3.13; the version gate and dropping@overridewere both real options.No merges: the three survivors are about different boundaries.
Citations
Only two existed.
docs/agents/domain.mdnames0002-keep-construction-factories.mdin itsfile-structure example, now
0002-no-per-call-middlewares-kwarg.md, and citesADR-0001in theconflict-flagging example, whose number is unchanged but whose parenthetical title was updated to
match the rewritten record. The intra-ADR
[ADR-0001](0001-fake-broker-keeps-immediate-delivery.md)link lived in the dropped record and went with it. No Python cites an ADR. The repo-wide sweep finds
no reference to an old or dropped number.
Stale claims
None. Every concrete claim was re-checked against the code and all of them still hold:
FakeTimersProducer.publishencodes throughTimerMessageFormat.encodeand callsprocess_messagedirectly,TestTimersBroker._patch_brokerstubszrangebyscore/zscore/thecancel_allpipeline,scheduled_timersexists,TimerStoreis a concrete class with noProtocoland no in-memory sibling, the subscriber's defaultpolling_intervalis still0.05,neither
TimersRegistrator.subscriber()/.publisher()norTimersRoute/TimersRoutePublishertakes
middlewares=whileTimersBroker/TimersRouterstill do,RedisClientis atyping.TypeAlias,overrideis imported unconditionally fromtyping_extensionsin all threemodules that use it,
typing-extensions>=4.12.0is a direct dependency andrequires-pythonis>=3.11. Two details worth naming: the dropped record's premise was accurate (create_publisherand
create_subscriberreally are single-caller pass-throughs), anddatetime.UTC, the constant0004 credited with fixing 3.11 as the floor, is still imported in
response.py.Gates
pytest -q tests/test_adr_citations.pypytest -q(no-Redis suites:test_unit,test_fake,test_store_seam,test_tuning_defaults,test_adr_citations)ruff format --checkruff check --no-fixeof-fixer . --checklychee --offlineover the three ADRs,docs/agents/domain.md,CONTEXT.md,AGENTS.mdThe integration suites (
test_at_least_once,test_cancel,test_concurrency,test_delivery,test_envelope,test_inspection,test_isolation,test_publish_api) need a live Redis and werenot run locally; CI covers them. No Python was touched, so the ruff and eof-fixer runs are
repo-wide rather than scoped to the change.