Derive extends' merge policy from KeySpec#47
Merged
Conversation
…rge change The Task 2 implementer could not find this file (it existed only as an uncommitted file in the main checkout, which the worktree's fresh base ref did not carry over) and reconstructed a shorter version from context, losing the Motivation, Non-goals, and Risk sections. Restore the original, already-reviewed design content; the finalized summary line is unchanged.
… design doc Final review caught two drift spots in the design file: illustrative code snippets still showed the 2-arg merge(base, local) signature superseded during implementation by the 4-arg (name, key, base, local) form, and the structural-key count said 8 instead of 9.
This was referenced Jul 13, 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
KeySpec(keys.py) gains amergefield, baked in automatically by the_list()/_map()factories, so a future_list/_mapkey can't silently skip extends support.extends.pynow derives concat/merge semantics for the 8SERVICE_KEYS-shaped keys fromspec.mergeinstead of a hand-copied_MERGE_KEYS/_CONCAT_KEYSset, closing a silent-drift failure mode (a forgottenextends.pyentry used to degrade "concatenate" to "last writer wins" with no error).labels/annotations(e.g.labels: ["team=core"]) now merge correctly acrossextends— previously an untested gap that raisedUnsupportedComposeError.KeySpec:environment,extra_hosts,healthcheck,depends_on,secrets,configs,volumes,tmpfs,env_file) keep their existing hand-maintained sets, shrunk and commented, deferring unification perdecisions/2026-07-12-reject-structural-key-registry.md.Full rationale:
planning/changes/2026-07-13.05-derive-extends-merge-policy-from-keyspec.md.Test plan
just test-ci— 401 passed, 100% line coveragejust lint-ci— clean (ruff format/check, ty, eof-fixer, planning check)