Repository navigation
spec(port): port specs/port/trios-railway/crates/trios-railway-core/src/mutations.t27 (Closes #9783) - #9862
Conversation
…rc/mutations.t27 (Closes gHashTag#9783) Port gHashTag/trios-railway:crates/trios-railway-core/src/mutations.rs (at 8b229e9489ee, 165 lines) as specs/port/trios-railway/crates/ trios-railway-core/src/mutations.t27 - Roadmap Stage 6, goal gHashTag#4548, target t27c gen-rust. The RW-03 mutations' decisions are ported as pure functions and tested (8 tests, 8 pass, 0 vacuous, 28 runtime asserts, 100% function coverage), including the original's own mutation_strings_present and created_service tests: the five mutation names (serviceCreate, variableUpsert, serviceInstanceRedeploy, serviceInstanceUpdate, serviceDelete) with the shared mutation M( prefix, the variable-key counts each carries (serviceCreate 2 and NOT the image - Railway splits service from service-instance config; variableUpsert 5, fully scoped; redeploy 2, reusing the most recent source; delete 1), the image pin landing on source.image, the redeploy answer's string-or-stringified rule, and the CreatedService shape under its serde names. The five required functions keep their names as plan verdicts; the GraphQL round-trips are the callers' plumbing, and no undefined transport is needed. Verified: parse OK, spec-status IMPLEMENTED, typecheck 0 errors, coverage 19/19, test-report 8/8 pass, 0 BLOCKED, gen 165 lines with 0 'not yet implemented', boundary exactly this one file, dupe_scan: all 14 introduced names unique across 2040 specs (checked before the commit), bare body scan adds no duplicate group (752/221 unchanged). Dmitrii Fedorov ([@dmitrii-f-t27](https://github.com/dmitrii-f-t27))
|
@gHashTag Please merge this PR into master via the golden chain — rights on gHashTag/t27 are read-only for me (403), so the merge itself needs your action. What this is: the #9783 port — What is verified:
CI (head 85550fd): required trio green — The 3 reds are the base-red trio, not this change: After the merge I will: verify the spec file live on the merge SHA, confirm #9783 auto-closed, and file the 14-step report. Dmitrii Fedorov (@dmitrii-f-t27) |
Summary
Port
gHashTag/trios-railway:crates/trios-railway-core/src/mutations.rs(at8b229e9489ee, 165 lines) asspecs/port/trios-railway/crates/trios-railway-core/src/mutations.t27— Roadmap Stage 6 (goal #4548), target t27c gen-rust. Closes #9783.The original is RW-03: the five typed mutations against the Railway GraphQL API — serviceCreate (image-based, project-scoped), variableUpsert (one variable at a time, fully scoped), serviceInstanceRedeploy (redeploy on the most recent source, answering the new deployment id), serviceInstanceUpdate (pinning source.image), and serviceDelete (permanent, deployments included). The R7 triplet is logged at the call site — this module returns plain ids.
Per the issue's rule ("Port the decision, not the plumbing"), all five listed functions are ported under their names as plan-verdict pure functions (no transports: the GraphQL round-trips are the callers' plumbing, so no
undefined;body is needed) with 8 tests (28 runtime asserts, 0 vacuous, 100% function coverage), including the original's own mutation_strings_present and created_service tests:mutation M(prefix;source.imageinside the instance update input;CreatedServiceshape under its serde names.Verification (all run live from the worktree root, zig 0.16.0)
t27c parse: OK.t27c spec-status: IMPLEMENTED.t27c typecheck: 0 errors, 0 warnings.t27c coverage: 19/19 tested (100%) — every helper directly asserted.t27c test-report: 8 tests / 8 pass / 0 FAIL / 0 BLOCKED, 0 vacuous passes.t27c gen | grep -c 'not yet implemented': 0;gen | wc -l: 165 (> 12).grep -cE '^\s*(pub )?fn (service_create|service_instance_set_image|variable_upsert|service_redeploy|service_delete)\(': 5.grep -cE '^\s*test\s+(["|[A-Za-z_])': 8 (≥ 5).git status --short— exactly this one file. The repo's lefthook pre-commit passed.dupe_scan: all 14 introduced names unique across 2040 specs (checked before the commit); the bare body scan adds no duplicate group (752 bodies / 221 groups on base, identical with this spec present).Dmitrii Fedorov (@dmitrii-f-t27)