Repository navigation
feat(composition): fragments join the properties of a subject, and a set two fragments declare differently is refused - #3
Draft
FBumann wants to merge 2 commits into
Conversation
…set two fragments declare differently is refused `merge` treats a set as it treats a relation, and joins the properties of one subject across fragments, holding a property two of them declare to be identical. `override` lays a set or a property over as a relation: added, restated, or its `missing:` changed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01W6yvGzZN2iR4WyA9RumvvJ
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01W6yvGzZN2iR4WyA9RumvvJ
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: true
Comment |
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.
Note
The following content was generated by AI.
What this changes
mergejoins the properties of one subject across fragments, and a property that two fragments declare must be identical in both. A set is shared as a relation is, so two fragments that declare it differently are refused. Stacked on #2.Why
This is PR 3 of the stack in which sets and properties replace relations.
What each verb does now
merge:generator: {bus: bus}in one fragment andgenerator: {zone: zone}in anothergenerator: {bus: bus, zone: zone}bus: busin one fragment andbus: {into: bus}in anothersite: busin one fragment andsite: zonein anothersay different things about the property 'generator.site': {'into': 'bus'} against {'into': 'zone'}. Make the two identical, or give one of them a name of its own.missing:differs between fragmentsoverridelays a set or a property over the base as it lays a relation:{missing: absent}on a property writtenbus: busbus: nullorgenerator: nullinto:dims:, orcover: nullmissing:on a setHow it works:
_flatlays the properties out as one entry per property, keyedsubject.propertyand in the long form. The existing rules for a shared entry (_agreedand_shared) then read each property, and_nestedputs the result back._sharednow takes the label and the schema class of its entries, and_declaredreads the validated fields rather than the serialised form, which writes a property as a bare string.Departures, and what this PR does not do
overrideis in scope too. The ask named merging only. In feat(language): a file may declare sets of labels and the properties of a dimension or a set #1,overridelaid properties over a subject as owned entries, and a patch could remove them. Because both verbs share one list of sections, addingsetsto it changesoverrideas well. So I made properties behave as relations do in both verbs. feat(language): a file may declare sets of labels and the properties of a dimension or a set #1's three tests for that interim behaviour are replaced by the tables above.into:is now refused by the schema,properties.generator.zone.into: Field required, as a partial new relation already is. In feat(language): a file may declare sets of labels and the properties of a dimension or a set #1 it was refused with a message of its own.docs/howto/compose.mdchanged, in both of its tables and in the "redeclared" section.Gates, and the mutation table
pixi run lint,pixi run test(3214 passed, 1 skipped) andpixi run docs-build(strict).compile-tex. Tectonic cannot download its bundle in this container.ci.ymlreturns 404. Actions must be turned on in the fork's settings.intomissing:on anything but a dimensionGenerated by Claude Code