Repository navigation
v1: an operation body parses requires R, .. and carries it on the operation (D13 step b0) - #12937
Conversation
… as a requires property (D13 step b0) The seed compiles the corpus, so it must parse the member v2 already admits (dag_grammar_op_requires_expr) before any extdeps operation can declare the resources it reaches. Carried only: one `requires` property per member, whose value is the parsed type expression; every v1 consumer of operation properties selects by name or prefix, so no other v1 behaviour reads it. Controls compile through the real seed route: one and two members compile; a non-type member and an empty requires refuse. Generated stage0 regeneration follows from CI's recipe. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
|
On review 73858's residual risk (whether every v1 consumer of an operation's properties selects them by name or prefix). I checked this before writing that comment; the readers on this base, found by grepping
So none of them can select a One weakness in my own controls. — sent from sleek-boar-665 |
claim_executor --required-regen (candidate written to target/stage0-regen-candidate; the only drifted mirror is v1_compiler_parse.rs). Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
briansrls
left a comment
There was a problem hiding this comment.
HOLD at exact head 83725b0723efb95a228254a166183a65a5f3cc41.
Two bounded test findings; the parser change itself otherwise looks coherent, the stage0 mirror is regenerated, and all exact-head checks are green.
P1 — the empty-requires control refuses for the wrong reason
The disclosed weakness is blocking. In the current fixture, parse_type_expr skips the newline and reads the next entry's output identifier as the purported requirement type. The parse then fails at that entry's {. Therefore a_requires_with_no_member_refuses would remain green even if the requires parser had no nonempty-list rule at all; it proves only that the resulting token stream eventually fails.
A refusal control must discriminate the rule it names. Use an otherwise-valid operation where requires is the final entry immediately before }, so the next token cannot begin a type expression, and pair it with the same operation without that line compiling cleanly. Alternatively inspect a parser result/error at the requires member boundary. Merely asserting !compiles(...) on a fixture that fails later is insufficient.
P1 — acceptance does not prove the members are carried
Both positive controls would still pass if the new arm parsed and consumed requires R, .. but discarded r.properties instead of concatenating them into modifier_props. That is especially important here because the PR correctly states that no ordinary v1 semantic consumer reads requires; compile success therefore cannot observe the central "carried as one property per member" claim.
Add one discriminating control at the parser or the existing generic property serializer showing:
- one member yields exactly one
requiresproperty whose value is that parsed type expression; and - two members yield two such properties in order.
The code currently appears to do this (concat(modifier_props, r.properties) and one minted property per recursion), but the behavior needs an executable observer because carrying—not merely accepting the spelling—is the purpose of step b0.
Exact-head floor, generated, emit-build, and witnesses pass. This hold is solely the two non-discriminating coverage gaps; no direct merge or check bypass.
…e }, paired with the same op without it compiling clean Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… consumer) and a seed query exposing it; carry controls Gap 2 of the #12937 review: acceptance does not show the members are carried. v1.compiler.parse operation_requires_members is the one reader of an operation's parsed requires members, in order; its production consumer is D13 step (c). compile_dag_operation_requires parses one source with the seed's own parser and returns the members through that reader; a parse error or missing service/operation refuses. Controls: one member, two in order, none. Seed-growth justification and primitive egress disposition rows filed. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…the surface roster projects them Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…s from src/v1 (claim_executor --required-regen) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
briansrls
left a comment
There was a problem hiding this comment.
APPROVE-MERGE at exact head 2800067ac7234b55e9e11cf7bd8ec763ab9cb9ca.
This supersedes my CHANGES_REQUESTED review 5384774721. No findings.
Both held P1s are resolved:
- The empty-
requiresdiscriminator now putsrequireslast, directly before the operation's}, soparse_op_requires_membersmeets the closer where a type expression must begin. The paired source differs only by removing that line and compiles cleanly. The negative can no longer stay green by consuming a following operation entry and failing incidentally later. - Carry is now observed, not inferred from compile acceptance.
v1.compiler.parse.operation_requires_membersis the one.dagreader of the parsedrequiresproperties and preserves their authored order.compile_dag_operation_requiresparses through the seed's tokenizer/parser, finds the named service and operation, and delegates to that reader; parse failure, missing service, and missing operation are refusals rather than empty results. The controls require exactly[Net],[Net, Fs], and[]for one, two, and absent clauses, so dropping, reordering, or fabricating the carried members is discriminated. - The reader has an honest DESIGN §3c standing: D13 step (c) is the named production consumer. The hand host exposure is bounded by a filed seed-growth justification and primitive-egress disposition, and the signature, primitive roster, authored dispatch surface, generated dispatch projection, and stage0 mirrors move together.
- Service children are the parser's
operationspopulation, so the host lookup cannot satisfy the operation name with an unrelated service member.
Exact-head floor, generated, emit-build, and witnesses all pass. GitHub reports the PR open, non-draft, clean, and mergeable.
Merge-queue landing only: the actual merge_group candidate must pass against then-current main; no direct merge or check bypass.
Why
D13 step (b) derives a function's resource demand partly from the
requiresedge of the service operations it calls (#12911). That edge has to be authored on realextdepsoperations, a ~500-op Network audit the lane owner dispatches next. But the corpus is compiled by the v1 seed, and v1 did not parserequires, so no operation could author it. This is that v1 parse change, ruled as a separate small PR: v1 parsesrequireson operations and carries it, with no other v1 behaviour change.What
v1.compiler.parseparse_op_body_entriesgains arequiresarm.parse_op_requires_membersreads a comma list of type expressions (parse_type_expr) and turns each member into onerequiresproperty whose value is the parsed type, carried beside the modifier properties.idempotent/readonly/hermetic,response_,exit_,mock_). The one generic reader iscompile.dag's property serializer, which dumps every property and only matters once an operation authorsrequires. No corpus operation does yet.src/v1/stage0/src/v1_compiler_parse.rs) is regenerated per the recipe CI's generated-artifact phase prints. (If that file is not yet in the diff, it follows in the next commit.)Controls (
test.claim.v1_operation_requires_parse_witness_test)Accepted (through the real seed compile,
compile_dag_rust_emit_check): one member, and two members, compile clean.Refused:
requires 123).requireswritten as the LAST entry, right before}, so the member reader meets the brace. It is paired with the identical operation without the line, which compiles clean.Carried, not only accepted.
v1.compiler.parseoperation_requires_membersis the one.dagreader of an operation's parsed members, in order. Its production consumer is D13 step (c) (§3c). The seed querycompile_dag_operation_requires(source, service, operation)parses with the seed's own parser and reads through that reader. A parse error, a missing service or a missing operation refuses; none answers an empty list. Controls:["Net"];["Net", "Fs"], in order;[].Filed with it:
04_method.dag);std.primitivesroster and the interpreter primitive surface row (dispatch projection);gunbc.operation_requires_query_seed_growth).The stage0 mirrors were regenerated with
claim_executor --required-regen.Noticed, not changed
parse_op_body_entriesalready accepts an unknownname: exprentry in an operation body and drops it (its last ShIdent arm). That is a silent drop, but it predates this change and is out of scope here; reported to the lane owner.🤖 Generated with Claude Code