FireMUD Delivery Status

PR data refreshed

PR #3246 review history

Retain selected template publication and original launch evidence

Unit 1A · identity, Account and public JOIN

Review rounds

Three-number pills mean: found (raw) / accepted here (useful) / routed

Hosted CodeRabbit3 completed
8/8/02/2/03/3/0
CLI CodeRabbit6 completed
9/9/04/4/04/4/03/2/02/2/0

Recorded review history

Reviews and findings

  1. Hosted Review 1 CompletedRuntime 10m 50s
    Found: 8 Accepted: 0/5/3 Routed: 0
    1. Map a deterministic invalid result to INTERNAL, not UNAVAILABLE.Minor

      AuthoredInitialActorCoreReadGrpcCodec.toResponse can throw IllegalArgumentException in two cases. The first case is an oversize wire response. The second case is a failed self-check in fromResponse. Either error repeats on every call with the same retained owner rows. This catch block reports the error as UNAVAILABLE, and gRPC callers treat UNAVAILABLE as transient and retryable. A Game Session or Entity caller with retry policy then retries a permanent failure. The sibling GameDesignStartSessionLaunchDescriptorGrpcService already maps IllegalArgumentException to INTERNAL (Lines 92-96). Use the same contract here.

      🐛 Proposed fix

      --- "a/services/game-design-service/src/main/java/net/firedevops/firemud/gamedesign/publication/GrpcAuthoredInitialActorCoreReadService.java"
      +++ "b/services/game-design-service/src/main/java/net/firedevops/firemud/gamedesign/publication/GrpcAuthoredInitialActorCoreReadService.java"
      @@ -72,12 +72,17 @@
           try {
             observer.onNext(AuthoredInitialActorCoreReadGrpcCodec.toResponse(service.read(decoded)));
             observer.onCompleted();
           } catch (StatusRuntimeException failure) {
             observer.onError(
                 Status.fromCode(Status.fromThrowable(failure).getCode())
                     .withDescription("Exact authored-core owner read denied or unavailable")
                     .asRuntimeException());
      +    } catch (IllegalArgumentException invalidResult) {
      +      observer.onError(
      +          Status.INTERNAL
      +              .withDescription("Game Design produced an invalid authored-core result")
      +              .asRuntimeException());
           } catch (RuntimeException unavailable) {
             observer.onError(
                 Status.UNAVAILABLE
                     .withDescription("Game Design authored-core owner read unavailable")
      
      • Accepted Accepted Minor: deterministic invalid owner/encoding results require sanitized INTERNAL; retain foreign status and infrastructure handling.
    2. Use the base-class lifecycle helpers instead of duplicating initialized and closed state.Trivial

      AbstractReloadingBlockingGrpcClient already provides initOnce(closedMessage, unavailableMessage) and requireInitializedStub(unavailableMessage). These methods keep closed and explicitlyInitialized under the same monitor as the channel. This class keeps a second, parallel copy of that state in the volatile fields on Line 28 and Line 29. It also reimplements the same checks in init(), close(), and requireStub(). Two state machines can drift apart if either one changes later. The other standalone clients in AuthoredCoreAndSpawnReadClientLifecycleTest probably use the shared helpers.

      ♻️ Proposed refactor

      --- "a/services/common-platform-core/src/main/java/net/firedevops/firemud/common/gamedesign/GrpcAuthoredInitialActorCoreReadClient.java"
      +++ "b/services/common-platform-core/src/main/java/net/firedevops/firemud/common/gamedesign/GrpcAuthoredInitialActorCoreReadClient.java"
      @@ -44,13 +44,10 @@
           this.workloadNamespace = workloadNamespace;
         }
       
      -  public synchronized void init() throws SSLException, IOException {
      -    if (closed) throw new IllegalStateException("Authored-core read client is closed");
      -    if (initialized) return;
      -    initReloadingClient();
      -    if (stub() == null) throw new IllegalStateException("Authored-core read client has no stub");
      -    initialized = true;
      -  }
      +  public void init() throws SSLException, IOException {
      +    initOnce(
      +        "Authored-core read client is closed", "Authored-core read client has no stub");
      +  }
       
         @Override
         public AuthoredInitialActorCoreReadEvidence.ReadResult read(
      

      Then replace requireStub() with requireInitializedStub("Authored-core read client is not initialized"). Remove the close() override and the two volatile fields.

      • Accepted Accepted Trivial: use existing shared lifecycle helpers and remove parallel local state while preserving TLS, request and close-drain behavior.
    3. Add a Capability Status row for the published spawn-requirements read.Minor

      The tracker contains the required table, but it has no row for this new capability. Add a row with:

      • Design: world-management-service/api-contracts.md#implementation-status
      • Implementation anchors: WorldPublishedSpawnRequirementsReadOwner and WorldPublishedSpawnRequirementsReadGrpcService
      • Proof anchors: WorldPublishedSpawnRequirementsReadOwnerTest and WorldPublishedSpawnRequirementsClientMtlsTest
      • Gaps: unregistered transport, the denied Game Design complete-launch producer, and no genuine upstream authority
      • Accepted Accepted Minor: record the standalone published spawn-read capability and actual owner/client proof anchors with remaining authority and registration gaps.
    4. Split the new tenant-predicate observation into the required entry fields.Minor

      This entry puts the title, context, observation and expected pattern in one sentence block. The file defines a required entry format with a short title and Context, Observation and Expected pattern sub-bullets. Every other entry in this file uses that format. A health-check pass needs the fields kept apart to decide later whether to keep or remove the entry.

      📝 Proposed restructure

      --- "a/design/project-management/ai-observations.md"
      +++ "b/design/project-management/ai-observations.md"
      @@ -140,7 +140,10 @@
         - Recovery: the next foreground canonical attempt on `3c71c8c24379af623ca66550a4f4acaadd0ffd81` completed at 05:27:42 UTC with exit zero, full terminal capture, held-edge and backend proof, authenticated teardown and independently absent project resources. This does not establish why the earlier owner ended.
         - Reconsideration trigger: a subsequent canonical attempt completes with terminal capture, or bounded process evidence identifies why the previous owner ended.
       
      -- `2026-10-16`: Qualify tenant mutation predicates before relying on filtered readback or later owner guards. The template repository's global-ID update could rewrite a retained row's tenant before returning it under the supplied tenant; a tenant-filtered readback did not protect the original row. Test controlled pre-phase rows as well as later guarded owners: the native counterexample changed the complete row and `xmin`, while the restored exact tenant predicate preserves both owner rows and their versions. Keep the create-only ID refusal before mapper/repository access, and separate this owner-local SQL proof from authenticated creator or hosted-content readiness.
      +- `2026-10-16`: Qualify tenant mutation predicates before relying on filtered readback or later owner guards
      +  - Context: the template repository's global-ID update path.
      +  - Observation: the update could rewrite a retained row's tenant before it returned the row under the supplied tenant. A tenant-filtered readback did not protect the original row. The native counterexample changed the complete row and `xmin`.
      +  - Expected pattern: test controlled pre-phase rows as well as later guarded owners. Keep the exact tenant predicate, which preserves both owner rows and their versions. Keep the create-only ID refusal before mapper/repository access. Separate this owner-local SQL proof from authenticated creator or hosted-content readiness.
       
       - `2026-10-16`: Derive focused Gradle selectors from declared Java packages
         - Context: a Gameplay capture proof supplied `integration.net...` as the selector, and Gradle executed no tests before failing discovery.
      

      As per coding guidelines: "Entry format: - YYYY-MM-DD: short title - Context: where it appeared - Observation: what was surprising or wasteful - Expected pattern: what should happen instead".

      • Accepted Accepted Minor: restructure only this PR-owned tenant-predicate observation into existing required fields, preserving every technical statement.
    5. Call requireExactVersionIdentity or remove it.Trivial

      PMD reports that requireExactVersionIdentity is an unused private method. The method checks one thing that applyFreezeAndCapture (lines 135-142) does not check: whether intake.operationId() equals version.sourceIntakeReceipt().operationId(). As written, a caller can supply an AppliedGraph whose Version receipt belongs to a different source intake. The freeze then proceeds against that mismatched pair. The tracker also records an earlier full-gate failure caused by an unused fixture local. Call the guard after the existing target check.

      🛡️ Proposed fix

           long expectedStateEpoch = Long.parseLong(selection.intent().expectedVersionStateEpoch());
           var intake = worldGraph.sourceIntake();
           var version = worldGraph.versionIdentity();
      +    requireExactVersionIdentity(selection, intake, version);
           var controlledWorldSource = worldGraph.controlledWorldSource();
      
      • Accepted Accepted Trivial: invoke the existing exact Version/intake identity guard before any freeze SQL or controlled Account callback; add focused refusal proof.
    6. Update the stale status bullets on normalized references and tenant phase.Minor

      This PR makes two Implementation Status bullets inaccurate:

      • Line 23 says there are "no normalized reference tables, create/update derivation and atomic synchronization, one-time backfill/validation marker". The PR adds each of these:
      • TemplateReferenceRepository.synchronizeCurrentProjection writes game_template_version_ref inside the source application transaction.
      • validateAndEnforce performs the persisted BACKFILLING → VALIDATED → ENFORCED cutover.
      • GameTenantCreationRepository.createCandidate initializes BACKFILLING.
      • Line 22 says current launch resolution does not consume the durable tenant phase. StartSessionTemplateAssociationReadService and StartSessionLaunchDescriptorProducer now require Phase.ENFORCED with an exact phaseEpoch.

      The tracker (lines 55 and 67) already records these facts. Line 24 of this file was updated, but lines 22–23 still say the work is target-only. Edit both bullets to state the actual position:

      • The repository-local projection, the phase storage and the cutover primitive exist.
      • The new StartSession reads consume the persisted phase.
      • The GetTemplateReferencePhase RPC, a registered cutover owner, retirement/reference-query tooling and production launch enforcement are still unimplemented.

      As per path instructions: "Review docs for canonical-current-state consistency. Flag obsolete transitional guidance, conflicts between architecture docs…"

      • Accepted Accepted Minor: current base-reference projection, persisted phase and passive phase consumers exist; correct stale status without claiming registration or all normalized tables.
    7. Use the inherited initOnce and requireInitializedStub helpers instead of duplicate lifecycle state.Trivial

      AbstractReloadingBlockingGrpcClient already provides initOnce(closedMessage, unavailableMessage) and requireInitializedStub(unavailableMessage). Both use the base class's synchronized closed and explicitlyInitialized state. This client adds its own volatile initialized and closed fields. It also re-implements the same checks and overrides close() only to reset those fields. The two sets of flags can drift if one of them changes later. Delegate to the base helpers and remove the local fields and the close() override.

      ♻️ Proposed refactor

      -  private final String workloadNamespace;
      -  private volatile boolean initialized;
      -  private volatile boolean closed;
      +  private final String workloadNamespace;
      @@
         public synchronized void init() throws SSLException, IOException {
      -    if (closed) {
      -      throw new IllegalStateException("World spawn-requirements client is closed");
      -    }
      -    if (initialized) {
      -      return;
      -    }
      -    initReloadingClient();
      -    if (stub() == null) {
      -      throw new IllegalStateException("World spawn-requirements client has no gRPC stub");
      -    }
      -    initialized = true;
      +    initOnce(
      +        "World spawn-requirements client is closed",
      +        "World spawn-requirements client has no gRPC stub");
         }
      @@
      -  @Override
      -  public void close() throws IOException {
      -    synchronized (this) {
      -      closed = true;
      -      initialized = false;
      -    }
      -    super.close();
      -  }
      -
         private WorldPublishedSpawnRequirementsReadServiceGrpc
                 .WorldPublishedSpawnRequirementsReadServiceBlockingStub
             requireStub() {
      -    var currentStub = stub();
      -    if (closed || !initialized || currentStub == null) {
      -      throw new IllegalStateException(
      -          "World spawn-requirements client is not initialized and available");
      -    }
      -    return currentStub;
      +    return requireInitializedStub(
      +        "World spawn-requirements client is not initialized and available");
         }
      

      Also applies to: 108-126

      • Accepted Accepted Trivial: use existing shared lifecycle helpers and remove parallel local state while preserving workload identity and transport behavior.
    8. Move the focused test-pass count to the authoring tracker.Minor

      Line 115 records a point-in-time result in an architecture contract: "All fourteen focused RevisionServiceImplTest cases pass". This text goes stale when someone adds or removes a test case. It also makes the architecture document a second record of proof status. Keep the contract statement here, which says that GAMEPLAY_RULE is rejected before repository or World client access. Move the case count and the mock-scope limit to the linked authoring tracker.

      📝 Proposed wording change

      -... Other ordinary revision requests without a World mutation retain their local save path. All fourteen focused `RevisionServiceImplTest` cases pass, including both early gameplay-rule refusals and the existing ordinary and World-call ordering cases. These controlled repository and client mocks do not establish coordinated rule authoring, an authenticated creator flow or a successful registered handoff. See ...
      +... Other ordinary revision requests without a World mutation retain their local save path. Focused proof and its controlled-mock limits are recorded in [the authoring tracker](../../../project-management/implementation-tracking/game-authoring-publishing-and-activation.md#current-status); they do not establish coordinated rule authoring, an authenticated creator flow or a successful registered handoff. See ...
      

      As per path instructions, "Architecture owns technical target state". As per coding guidelines, "The domain implementation trackers record capability, code, and proof status".

      • Accepted Accepted Minor: proof counts belong in the owning authoring tracker; preserve the API refusal contract and controlled-scope limitations.
  2. CLI Review 1 CompletedRuntime 3m 06s
    Found: 6 Accepted: 0/3/1 Routed: 0
    1. Confirm that the new Capability Status row passes the tracker contract checks.Minor

      The new row has no capability identifier. Every other row in this table uses one, for example GR-2.1. The Capability Allocation ledger is the exhaustive handoff ledger. A row without an allocation ID may therefore fail dev-tools/tests/architecture-doc-contracts.sh, or it may leave the capability unallocated.

      The Secondary handoffs cell links to ../../architecture/microservices/game-design-service/api-contracts.md#authored-world-launch-binding. The supplied excerpts of that file do not include this heading. The link may be broken.

      Do these steps:

      • Add or reuse an allocated capability ID for this row.
      • Confirm that the #authored-world-launch-binding anchor resolves. If it does not resolve, link to an existing section, such as #implementation-status.
      • Run ./gradlew linkCheck lintMarkdown and bash dev-tools/tests/architecture-doc-contracts.sh.

      As per coding guidelines: "Each tracker contains one Capability Status row for every capability it primarily owns… Evidence targets must be repository-local and resolvable." As per path instructions: "Flag … broken repo links."

      • Accepted Unallocated standalone CapabilityStatus row should fold into existing allocated World GR-2.1 row preserving all source/proof anchors. Claimed broken link is valid: GameDesign has Authored-World Launch Binding heading.
    2. Confirm that consumers of worldSelectedPublicationProof also receive the World main classes.Major

      The proof JAR contains only the WorldSelectedFullPublicationEvidenceFixture*.class files from the integrationTest output. The fixture calls many World main-source types, for example WorldDesignPublicationFenceRepository, WorldDraftGraphApplicationService, WorldCanonicalFrozenTopologyService, and WorldPublishedStartLocationRepository. extendsFrom(configurations.implementation.get()) exposes only the declared external and project dependencies. It does not expose this project's own main output, and it does not expose runtimeOnly dependencies.

      The consumer is the GDS schema-4 proof. If that consumer does not get :world-management-service main classes through another dependency, the fixture compiles against an incomplete classpath or fails at runtime with NoClassDefFoundError.

      Check the consuming build.gradle.kts. If it does not add World's main output separately, add the main JAR to the outgoing artifacts:

      Possible fix

       val worldSelectedPublicationProof by configurations.creating {
           isCanBeConsumed = true
           isCanBeResolved = false
           extendsFrom(configurations.implementation.get())
      +    extendsFrom(configurations.runtimeOnly.get())
      +    outgoing.artifact(tasks.named("jar"))
           outgoing.artifact(worldSelectedPublicationProofJar)
       }
      
      • Rejected Existing published consumer caa149577173 GameDesign build lines46-52 explicitly adds BOTH worldClassesProof and worldSelectedPublicationProof. Separate classes-only artifact supplies World main classes while excluding service resources; existing physical composition qualifies it.
    3. Replace the unchecked DescriptorOutcome cast with a closed type check.Minor

      The response is built from server-supplied association_read and launch_descriptor fields. Suppose StartSessionLaunchDescriptorGrpcCodec.fromResponse decodes a failure outcome instead of a descriptor outcome. The cast on Line 102 then throws ClassCastException. That exception is not an IllegalArgumentException. GrpcAuthoredInitialActorCoreReadClient.read catches only IllegalArgumentException. The client therefore leaks a raw ClassCastException and does not report its documented IllegalStateException ("Game Design returned invalid authored-core evidence"). Reject a non-descriptor outcome explicitly.

      🛡️ Proposed fix

           var resolved =
               StartSessionLaunchDescriptorGrpcCodec.fromResponse(expectedRequest, descriptorEnvelope);
      -    var descriptor =
      -        ((StartSessionLaunchDescriptorGrpcCodec.DescriptorOutcome) resolved.outcome()).descriptor();
      +    if (!(resolved.outcome()
      +        instanceof StartSessionLaunchDescriptorGrpcCodec.DescriptorOutcome descriptorOutcome)) {
      +      throw new IllegalArgumentException("Authored-core read requires a successful descriptor");
      +    }
      +    var descriptor = descriptorOutcome.descriptor();
      
      • Rejected Core decoder requires hasLaunchDescriptor and locally constructs envelope with only setLaunchDescriptor. Descriptor codec branches on that exact field, returning DescriptorOutcome or throwing IllegalArgumentException. ApplicationFailure cannot reach this cast.
    4. Shorten the identifiers that exceed the PostgreSQL 63-byte limit.Trivial

      These identifiers are longer than 63 bytes:

      • The table game_session_original_start_session_authored_actor_core_retention is 65 bytes. PostgreSQL stores it as ..._actor_core_retenti.
      • The trigger game_session_original_start_session_actor_core_retention_no_truncate is 68 bytes. PostgreSQL stores it as ..._retention_no_tru.

      PostgreSQL truncates both names. It emits only a NOTICE. The code continues to work because every lookup is truncated in the same way. These lookups include the TABLE constant in GameSessionAuthoredActorCoreRetentionRepository, the regclass and name casts in CommunicationWebSocketCrossServiceTest, and the relname filters in CanonicalInitialAdmissionRepositoryIntegrationTest. assertV1013RetentionLaunchForeignKey asserts the truncated name explicitly.

      The catalog names therefore differ from the names in the source. This causes these problems:

      • Catalog queries and generated code that do not truncate can resolve a different name.
      • A future name that shares the same first 63 bytes collides with this name.
      • jOOQ DDL simulation of the CREATE TABLE is not inside a [jooq ignore] block. It can keep the full 65-character name.

      V1013 is new in this change. Rename the objects now, before any deployment retains the truncated names. Update the Java constant, the test enum, and the test assertions to use the same names.

      ♻️ Example rename

      -CREATE TABLE game_session_original_start_session_authored_actor_core_retention (
      +CREATE TABLE gs_original_start_session_authored_actor_core_retention (
      ...
      -CREATE TRIGGER game_session_original_start_session_actor_core_retention_no_truncate
      -    BEFORE TRUNCATE ON game_session_original_start_session_authored_actor_core_retention
      +CREATE TRIGGER gs_original_start_session_actor_core_retention_no_truncate
      +    BEFORE TRUNCATE ON gs_original_start_session_authored_actor_core_retention
      

      Also applies to: 178-180

      • Accepted New unmerged V1013 uses overlong table/trigger names and tests depend on truncation. Converge identifiers below63 bytes and every exact repository/fixture/catalog reference; retain all guards/history/assertions and prove actual PostgreSQL migration.
    5. Stop mapping every Game Design failure to UNAVAILABLE.Minor

      readLaunchBinding catches every RuntimeException and returns UNAVAILABLE. Some of these failures are permanent:

      • Game Design can return an application StatusRuntimeException such as NOT_FOUND, PERMISSION_DENIED, INVALID_ARGUMENT, or FAILED_PRECONDITION.
      • The client codec can throw IllegalArgumentException when the returned evidence is inconsistent.

      UNAVAILABLE tells the Entity caller that the error is transient and that it can retry. A missing or mismatched launch binding then produces repeated retries and is never reported as a terminal outcome. The path instructions ask for correct gRPC application-error handling.

      Keep transport-level UNAVAILABLE and DEADLINE_EXCEEDED as UNAVAILABLE. Map NOT_FOUND to NOT_FOUND. Map invalid or inconsistent evidence to FAILED_PRECONDITION. Add a test that covers a non-transient Game Design status.

      Proposed fix

         private CompleteLaunchBindingEvidence readLaunchBinding(Request request) {
           try {
             return gameDesignClient.getComplete(request.launchBindingRequest());
      +    } catch (io.grpc.StatusRuntimeException failure) {
      +      switch (failure.getStatus().getCode()) {
      +        case UNAVAILABLE, DEADLINE_EXCEEDED, RESOURCE_EXHAUSTED, ABORTED ->
      +            throw rejected(
      +                Status.Code.UNAVAILABLE, "Authenticated Game Design release read did not complete");
      +        case NOT_FOUND ->
      +            throw rejected(Status.Code.NOT_FOUND, "No exact Game Design release matches the selector");
      +        default ->
      +            throw rejected(
      +                Status.Code.FAILED_PRECONDITION,
      +                "Authenticated Game Design release evidence was rejected");
      +      }
      +    } catch (IllegalArgumentException | IllegalStateException inconsistent) {
      +      throw rejected(
      +          Status.Code.FAILED_PRECONDITION,
      +          "Authenticated Game Design release evidence is inconsistent");
           } catch (RuntimeException unavailable) {
             throw rejected(
                 Status.Code.UNAVAILABLE, "Authenticated Game Design release read did not complete");
           }
         }
      
      • Accepted World launch dependency maps every failure to UNAVAILABLE. Preserve canonical six infrastructure codes, sanitize deterministic foreign refusals to local FAILED_PRECONDITION and invalid/unexpected responses to INTERNAL; focused privacy/status proof.
    6. Write each identity's credentials to its own files.Minor

      clientProperties writes every identity to the same fixed paths: entity-client.crt, entity-client.key and client-trust-ca.crt. These paths are under the shared static @TempDir. rejectsWrongLocalWorkloadPlaintextAndNonFileBackedTls writes wrongClient credentials to these paths. Other tests write the Entity credentials to the same paths. The tests stay correct only if they run sequentially. The sibling lifecycle test uses @ResourceLock, which suggests that JUnit parallel execution can be enabled. If parallel execution is on, one test can overwrite the certificate that another test's client is about to load. The result is a nondeterministic identity-check failure.

      Confirm the module's junit.jupiter.execution.parallel settings. Derive the file names from the identity regardless of the result, because this fix is cheap.

      ♻️ Proposed fix

           private CommonGrpcClientProperties clientProperties(Path directory, TestIdentity identity)
               throws Exception {
      +      String prefix = Integer.toHexString(identity.certificate().getSerialNumber().hashCode());
             Path certificate =
                 writePem(
      -              directory.resolve("entity-client.crt"),
      +              directory.resolve(prefix + "-client.crt"),
                     "CERTIFICATE",
                     identity.certificate().getEncoded());
             Path privateKey =
                 writePem(
      -              directory.resolve("entity-client.key"),
      +              directory.resolve(prefix + "-client.key"),
                     "PRIVATE KEY",
                     identity.privateKey().getEncoded());
      
      • Accepted Distinct test identities overwrite one shared cert/key filename. Use full identity serial for separate file paths while retaining shared CA and all existing PKI/timeouts. Useful fixture isolation regardless of current parallel setting.
  3. Hosted Review 2 CompletedRuntime 14m 24s
    Found: 2 Accepted: 1/0/1 Routed: 0
    1. Assert that no response is delivered on the INTERNAL path.Trivial

      The test name says the handler "never masks observer delivery". The test checks only the status code and description. It does not check observer.value or observer.completed. A regression could call onNext/onCompleted after onError, and this test would still pass. Add the same assertions that the first test uses.

      ♻️ Proposed change

           assertThat(observer.error).isEqualTo(Status.Code.INTERNAL);
           assertThat(observer.description).isEqualTo("Published World source read failed");
           assertThat(observer.description).doesNotContain("private exception detail");
      +    assertThat(observer.value).isNull();
      +    assertThat(observer.completed).isFalse();
         }
      
      • Accepted Trivial: bounded INTERNAL regression currently omits no-payload and no-completion assertions. Add the two assertions in the existing test to protect observer error delivery; production behavior unchanged.
    2. Exclude templates whose latest source revision is DELETE.Major

      TemplateConfigSourceRepository.apply keeps the game_templates row and its qualification row for DELETE. It records an immutable source revision with operation_kind = 'DELETE'. readCompleteInventory selects the physical row without checking that latest operation, so the deleted template enters templatesByVersion while the visible snapshot omits it. The size check then throws TEMPLATE_REFERENCE_INVENTORY_SOURCE_SET_CONFLICT, which can block validateAndEnforce while the template remains deleted.

      Do not filter on any historical DELETE. Use the same latest-revision ordering as template_config_current_inventory, so a later active revision remains eligible. Add a PostgreSQL case for CREATE → DELETE → validateAndEnforce.

      Suggested inventory predicate

                       + "FROM game_templates t LEFT JOIN game_design_template_config_source_qualification q "
      -                + "ON q.template_id = t.id WHERE t.tenant_id = ? ORDER BY t.id",
      +                + "ON q.template_id = t.id "
      +                + "LEFT JOIN LATERAL ("
      +                + "SELECT r.operation_kind "
      +                + "FROM game_design_template_config_source_revision r "
      +                + "JOIN game_design_template_config_source_application a "
      +                + "ON a.canonical_tenant_id = r.canonical_tenant_id "
      +                + "AND a.canonical_version_id = r.canonical_version_id "
      +                + "AND a.commit_id = r.commit_id "
      +                + "WHERE r.canonical_tenant_id = q.canonical_tenant_id "
      +                + "AND r.canonical_version_id = q.canonical_version_id "
      +                + "AND r.template_id = t.id "
      +                + "ORDER BY a.expected_epoch::NUMERIC DESC, r.revision_order DESC LIMIT 1"
      +                + ") latest ON TRUE "
      +                + "WHERE t.tenant_id = ? AND latest.operation_kind IS DISTINCT FROM 'DELETE' "
      +                + "ORDER BY t.id",
      
      • Accepted Major: physical tombstones remain after DELETE while visible source omits them, so current inventory falsely conflicts. Filter only latest applied DELETE with canonical numeric epoch/revision ordering; retain empty/unqualified denials and prove PostgreSQL deletion/reactivation.
  4. Hosted Review 3 CompletedRuntime 9m 16s
    Found: 3 Accepted: 0/3/0 Routed: 0
    1. Refuse an ambient owner transaction before the blocking World read.Minor

      GrpcAuthoredInitialActorCoreReadClient.read rejects an active Spring transaction before it calls the remote owner. This client does not. An Entity caller can therefore call read while it holds an open owner transaction. The blocking call can then keep that transaction open for up to the 5-second deadline.

      The architecture contracts require the authenticated remote reads to happen before the owner transaction. The World server guard only checks World's own transaction. It does not protect the calling Entity service. The base class already has requireNoAmbientSql. Call it at the start of read.

      🛡️ Proposed fix

      --- "a/services/common-platform-core/src/main/java/net/firedevops/firemud/common/world/WorldPublishedSpawnRequirementsClient.java"
      +++ "b/services/common-platform-core/src/main/java/net/firedevops/firemud/common/world/WorldPublishedSpawnRequirementsClient.java"
      @@ -54,10 +54,11 @@
         }
       
         /** Reads and validates the complete immutable source evidence for one exact selector. */
         public WorldPublishedSpawnRequirementsEvidence read(
             WorldPublishedSpawnRequirementsEvidence.Request request) {
      +    requireNoAmbientSql("World spawn-requirements read requires no ambient transaction");
           Objects.requireNonNull(request, "request");
           if (!workloadNamespace.equals(request.targetNamespace())) {
             throw new IllegalArgumentException(
                 "World spawn-requirements request must use the configured workload namespace");
           }
      
      • Accepted Valid missing caller-side no-ambient-SQL guard; reject transaction and synchronization before request validation or blocking World RPC.
    2. Bind the retained game instance on the exact-retry path.Minor

      The first-write path checks the actual launch against historical.launchAssociation(). That check includes gameInstanceUuid. The retry path in requireStoredRetryMatches returns the stored row without that check. A retry can supply historical evidence whose launchAssociation().gameInstanceUuid() differs from the retained candidate.gameInstanceUuid(). The method then returns the stored row instead of failing closed. The Game Session runtime contract requires replays to stay bound to the exact original association. Add the instance identity to the retry comparison.

      🛡️ Proposed fix

               || !candidate.ownerAttemptId().equals(request.expectedOwnerAttemptId())
               || !candidate.ownerMutationId().equals(request.expectedOwnerMutationId())
               || candidate.ownerFence() != request.expectedOwnerFence()
      +        || !candidate.gameInstanceUuid().equals(historical.launchAssociation().gameInstanceUuid())
               || !Arrays.equals(
      

      As per path instructions, keep "reads bound to the exact original operation, owner attempt, association, and retained evidence".

      • Accepted Valid retained retry omission; historical game instance must equal retained candidate before exact retry returns without new owner work.
    3. Return INTERNAL, not UNAVAILABLE, when the response cannot be encoded.Minor

      service.read already converts its own runtime failures to StatusRuntimeException. The only failure that reaches this generic catch is StartSessionTemplateAssociationReadGrpcCodec.toResponse(...) throwing IllegalArgumentException while it encodes the result. That failure repeats on every call with the same stored association rows. gRPC callers treat UNAVAILABLE as temporary and retryable, so a Game Session caller with a retry policy retries a permanent failure.

      GameDesignStartSessionLaunchDescriptorGrpcService (Lines 92-96) already maps this case to INTERNAL. The earlier review of GrpcAuthoredInitialActorCoreReadService corrected the same mapping. Apply the same rule here.

      🐛 Proposed fix

      --- "a/services/game-design-service/src/main/java/net/firedevops/firemud/gamedesign/draft/GameDesignStartSessionTemplateAssociationReadGrpcService.java"
      +++ "b/services/game-design-service/src/main/java/net/firedevops/firemud/gamedesign/draft/GameDesignStartSessionTemplateAssociationReadGrpcService.java"
      @@ -61,12 +61,17 @@
             observer.onNext(
                 StartSessionTemplateAssociationReadGrpcCodec.toResponse(service.read(decoded)));
             observer.onCompleted();
           } catch (StatusRuntimeException failure) {
             observer.onError(
                 Status.fromCode(Status.fromThrowable(failure).getCode())
                     .withDescription("Exact StartSession association read denied or unavailable")
                     .asRuntimeException());
      +    } catch (IllegalArgumentException invalidResult) {
      +      observer.onError(
      +          Status.INTERNAL
      +              .withDescription("Game Design returned an invalid StartSession association")
      +              .asRuntimeException());
           } catch (RuntimeException unavailable) {
             observer.onError(
                 Status.UNAVAILABLE
                     .withDescription("Game Design template association owner read unavailable")
      
      • Accepted Valid permanent result-encoding failure; bound IllegalArgumentException to INTERNAL while preserving generic unavailable handling.
  5. CLI Review 2 CompletedRuntime 3m 10s
    Found: 9 Accepted: 2/7/0 Routed: 0
    1. Use the service-scoped filesystem migration location for consistency.Minor

      This test loads migrations from classpath:db/migration. The other new game-design-service PostgreSQL tests in this change use filesystem:src/main/resources/db/migration. Examples are GameDesignSourcePostgresIntegrationTest, SelectedDraftGameLogicReceiptPostgresIntegrationTest and GameTemplateRepositoryPostgresIntegrationTest. Another module on the test classpath can contribute migrations at the same location. If that happens, Flyway fails with duplicate-version errors, or it applies foreign migrations. Confirm that the game-design-service test runtime classpath contains no other db/migration resources. Otherwise, switch both Flyway configurations to the filesystem location.

      🔧 Proposed fix

      -            .locations("classpath:db/migration");
      +            .locations(
      +                "filesystem:"
      +                    + java.nio.file.Path.of("src/main/resources/db/migration")
      +                        .toAbsolutePath()
      +                        .normalize());
      

      Also applies to: 1564-1564

      • Accepted Valid test isolation: both Flyway configurations must use service-scoped migration directory.
    2. Exempt retained operations from the new template-capture requirement.Major

      Line 347 throws GAME_DESIGN_SOURCE_CAPTURE_INCOMPLETE when template genesis is enrolled but no template capture exists. The rule has no exemption for retained operations. Template genesis and storage were enrolled before this change (V1008/V1025), but freeze only begins writing a template capture in this change. An operation reserved or sealed before this change can therefore have template genesis without a template capture. This applies to v1 operations and to terminal v2 operations. For that operation, readCapture now fails where it previously returned the retained capture. Exact terminal readback and replay then fail for that operation, and the failure does not recover.

      The gameplay check on Line 346 already handles the same transition. It accepts a missing capture when the operation is historical (historicalOperation) or terminal (historicalGameplay). Apply the equivalent exemption to the template capture. Keep the strict requirement for fresh, pending v2 operations.

      🐛 Proposed fix

      +    boolean historicalTemplate =
      +        historicalOperation || (templateConfig.isEmpty() && operationIsTerminal(operation));
           if (command.isEmpty()
               || policy.isEmpty()
               || (asset.isEmpty() && !historicalOperation)
               || (gameplayCapture.isEmpty() && !historicalOperation && !historicalGameplay)
      -        || (templateSourceEnrolled && templateConfig.isEmpty())) {
      +        || (templateSourceEnrolled && templateConfig.isEmpty() && !historicalTemplate)) {
      

      Confirm whether any retained operation can have template genesis without a template capture. Check whether TemplateConfigSourceRepository.freeze was called on any earlier publication path.

      • Accepted Valid historical readback regression: predecessor had no template capture freeze; preserve v1 and terminal retained captures without new provenance, fresh pending v2 stays strict.
    3. Do not map non-transient storage failures to UNAVAILABLE.Minor

      Both catch blocks return UNAVAILABLE. The separate TransientDataAccessException branch has no effect. As a result, a deterministic failure such as BadSqlGrammarException or DataIntegrityViolationException is reported as "temporarily unavailable". Callers then retry a read that cannot succeed. WorldCanonicalInstanceLifecycleReadRepository keeps non-transient failures distinct (see preservesNontransientSpringAndJooqStorageFailuresAtMaterializedReadBoundary). Map only transient and recoverable failures to UNAVAILABLE, and map other DataAccessException failures to INTERNAL.

      🐛 Proposed fix

      -    } catch (TransientDataAccessException unavailable) {
      +    } catch (TransientDataAccessException
      +        | org.springframework.dao.RecoverableDataAccessException unavailable) {
             throw rejected(Status.Code.UNAVAILABLE, "World published source is temporarily unavailable");
      -    } catch (DataAccessException unavailable) {
      -      throw rejected(Status.Code.UNAVAILABLE, "World published source is temporarily unavailable");
      +    } catch (DataAccessException storageFailure) {
      +      throw rejected(Status.Code.INTERNAL, "World published source read failed");
           } catch (RuntimeException failure) {
      
      • Accepted Valid storage classification: transient and recoverable World storage failures are retryable; other Spring DataAccess failures are bounded INTERNAL.
    4. Narrow the include pattern so the fixture test class stays out of the proof JAR.Minor

      The glob WorldSelectedFullPublicationEvidenceFixture*.class also matches WorldSelectedFullPublicationEvidenceFixtureTest.class. That unit test is in the same package and the same integrationTest output. The proof JAR therefore ships a test class that depends on Mockito and AssertJ. This contradicts the comment on Line 48, which says only the fixture classes cross the proof boundary. Match the top-level class and its nested classes explicitly.

      🐛 Proposed fix

           from(sourceSets["integrationTest"].output.classesDirs) {
      -        include("net/firedevops/firemud/worldmanagement/tenant/WorldSelectedFullPublicationEvidenceFixture*.class")
      +        include("net/firedevops/firemud/worldmanagement/tenant/WorldSelectedFullPublicationEvidenceFixture.class")
      +        include("net/firedevops/firemud/worldmanagement/tenant/WorldSelectedFullPublicationEvidenceFixture$*.class")
           }
      
      • Accepted Valid proof artifact leak: wildcard also selects FixtureTest.class; explicit top-level and nested-class patterns preserve only fixture API.
    5. Verify which DataAccessException type the injected DSLContext throws.Minor

      Line 91 catches only org.jooq.exception.DataAccessException and maps it to UNAVAILABLE. Spring Boot's jOOQ auto-configuration installs an exception translator. That translator converts jOOQ errors to org.springframework.dao.DataAccessException, and the code does not catch that type. If the injected DSLContext uses the translator, connection-acquisition or timeout failures reach the RuntimeException branch at Line 96. That branch returns permanent FAILED_PRECONDITION. The gRPC adapter keeps that code, so callers treat a transient storage outage as conflicting evidence and do not retry. The sibling owner reads documented in the Game Design API contract return retryable UNAVAILABLE for these failures.

      Confirm the exception type for the DSLContext that production composition will inject. If it can be the Spring type, also map the transient subclasses of org.springframework.dao.DataAccessException (for example TransientDataAccessException and DataAccessResourceFailureException) to UNAVAILABLE.

      🛡️ Proposed fix

           } catch (StatusRuntimeException failure) {
             throw failure;
      -    } catch (DataAccessException unavailable) {
      +    } catch (DataAccessException
      +        | org.springframework.dao.TransientDataAccessException
      +        | org.springframework.dao.DataAccessResourceFailureException unavailable) {
             throw Status.UNAVAILABLE
      
      • Accepted Valid translated Spring transient storage classification; fix actual association snapshot catch before status wrapping and preserve unrelated permanent handling.
    6. Assert the guard failure, not any RuntimeException.Minor

      The UPDATE, DELETE and TRUNCATE checks accept any RuntimeException. A malformed SQL string, a missing table or a wrong schema also passes these checks, so the test does not prove the append-only guard. Assert the trigger messages. The other pin assertions in this class already do this with hasStackTraceContaining.

      💚 Proposed fix

      -          .isInstanceOf(RuntimeException.class);
      +          .isInstanceOf(org.jooq.exception.DataAccessException.class)
      +          .hasStackTraceContaining("authored-core source retention is immutable and append-only");
       ...
      -          .isInstanceOf(RuntimeException.class);
      +          .isInstanceOf(org.jooq.exception.DataAccessException.class)
      +          .hasStackTraceContaining("authored-core source retention is immutable and append-only");
       ...
      -          .isInstanceOf(RuntimeException.class);
      +          .isInstanceOf(org.jooq.exception.DataAccessException.class)
      +          .hasStackTraceContaining("authored-core source retention cannot be truncated");
      
      • Accepted Valid physical guard proof gap: assert actual jOOQ failure and exact append-only/truncate trigger messages so malformed SQL cannot satisfy proof.
    7. Map a missing publication operation to FAILEDPRECONDITION.Minor

      Map a missing publication operation to `FAILED_PRECONDITION`.

      publicationOperations.read(...).orElseThrow() throws NoSuchElementException. All other owner-evidence failures in this method use conflict(...). The exception escapes writeTransaction.execute, so the gRPC adapter receives a non-status runtime exception. It probably maps it to UNKNOWN, not to the documented FAILED_PRECONDITION contract.

      🐛 Proposed fix

           var readback =
      -        publicationOperations.read(exact.association().publishWorkflowId()).orElseThrow();
      +        publicationOperations
      +            .read(exact.association().publishWorkflowId())
      +            .orElseThrow(() -> conflict("Exact selected publication operation is unavailable"));
      
      • Accepted Valid absent operation is deterministic owner conflict; use existing FAILED_PRECONDITION. Provider UNKNOWN claim inaccurate: current generic adapter maps UNAVAILABLE.
    8. Use the service-scoped filesystem migration location.Minor

      This test loads migrations from classpath:db/migration. It has the same exposure described for TemplateConfigSourcePostgresIntegrationTest. Other modules on the test classpath can contribute migrations at that location. Use filesystem:src/main/resources/db/migration, as the sibling game-design-service PostgreSQL tests do.

      🔧 Proposed fix

      -        .locations("classpath:db/migration")
      +        .locations(
      +            "filesystem:"
      +                + java.nio.file.Path.of("src/main/resources/db/migration")
      +                    .toAbsolutePath()
      +                    .normalize())
      
      • Accepted Valid test isolation: scope migration filesystem to owning service, preventing classpath foreign migration discovery.
    9. Use one shared release-bundle and release-content encoder for the producer and the association reader.Major

      toPublishedReleaseBundle(PublishedReleaseBundleDto) and releaseContent(PublishedReleaseBundleDto) are copied almost exactly from StartSessionTemplateAssociationReadService (Lines 569-672 in that file). The two copies are not independent. requireReleaseMatches compares the bundle from the association reader (exact.releaseBundle()) with the bundle that this producer builds (selected.equals(current)). It also compares the canonical bytes of the two ReleaseContent values.

      Suppose one copy changes, for example to add a field or to handle scriptPatchVersion or abilitySchemaDigest differently. Then every valid StartSession fails with "Current release row differs from the exact committed published release". Move both conversions into one package-private helper, for example PublishedReleaseEvidenceEncoding. Make both classes call it.

      ♻️ Proposed refactor

      -  private net.firedevops.firemud.gamedesign.v1.PublishedReleaseBundle toPublishedReleaseBundle(
      -      PublishedReleaseBundleDto dto) {
      -    var builder = ...
      -    return builder.build();
      -  }
      +  private net.firedevops.firemud.gamedesign.v1.PublishedReleaseBundle toPublishedReleaseBundle(
      +      PublishedReleaseBundleDto dto) {
      +    try {
      +      return PublishedReleaseEvidenceEncoding.toPublishedReleaseBundle(dto);
      +    } catch (IllegalStateException failedParticipant) {
      +      throw conflict("Published release participant did not succeed");
      +    }
      +  }
      

      Apply the same delegation in StartSessionTemplateAssociationReadService and for releaseContent(PublishedReleaseBundleDto).

      • Accepted Valid byte-equality maintenance risk: canonical package-private encoder for both DTO conversions; preserve all fields, canonical bytes and caller-specific conflict behavior.
  6. CLI Review 3 CompletedRuntime 3m 52s
    Found: 4 Accepted: 0/4/0 Routed: 0
    1. Fail with a clear error when no checkpoint was captured in this transaction.Minor

      capturedCheckpoint gets a value only when fence.claimFreeze calls the supplier. A freeze can already exist for the same publication, for example on a replay or a second call in an idempotency proof. In that case, the supplier does not run and capturedCheckpoint.get() returns null. Line 281 then throws an NullPointerException with no context. The fixture already passes capturedCheckpoint.get() (possibly null) to inventoryRepository.retainOrRequireExact at Line 226. Line 281 is the first unguarded dereference.

      Require the captured checkpoint before you build worldDigest. Alternatively, read the owner keys from the committed checkpoint.

      🛡️ Proposed fix

      +    var checkpoint =
      +        Objects.requireNonNull(
      +            capturedCheckpoint.get(),
      +            "World selected freeze reused an existing checkpoint; fixture requires a fresh capture");
           var worldDigest =
               new WorldDraftDesignDigestService.WorldDraftDesignDigest(
      -            Long.toString(capturedCheckpoint.get().owner().localTenantKey()),
      -            Long.toString(capturedCheckpoint.get().owner().localVersionKey()),
      +            Long.toString(checkpoint.owner().localTenantKey()),
      +            Long.toString(checkpoint.owner().localVersionKey()),
      
      • Accepted Valid Minor: replay can bypass checkpoint supplier and dereference null. Add explicit fixture fresh-capture refusal before using owner keys; no production behavior expansion.
    2. Set an explicit inbound message bound on the spawn-requirements stub.Minor

      GrpcAuthoredInitialActorCoreReadClient.buildStub raises its limit with withMaxInboundMessageSize(MAX_RESPONSE_WIRE_BYTES). This stub keeps the default gRPC inbound limit of 4 MiB. The response carries the complete GetCompleteLaunchBindingResponse, including the World selector receipt, the original Account binding and the applied-result bytes. It also carries unbounded spawn_requirements and generation_requirements lists. If an authored world exceeds 4 MiB, the client fails with RESOURCE_EXHAUSTED, and the wrapper in read does not report it as invalid evidence. The codec also defines no response bound for this read.

      Confirm the maximum realistic response size for this read. Then define a MAX_RESPONSE_WIRE_BYTES constant in WorldPublishedSpawnRequirementsGrpcCodec and apply it in both the stub and fromResponse.

      🛡️ Proposed bound

           return WorldPublishedSpawnRequirementsReadServiceGrpc.newBlockingStub(channel)
      +        .withMaxInboundMessageSize(WorldPublishedSpawnRequirementsGrpcCodec.MAX_RESPONSE_WIRE_BYTES)
               .withCallCredentials(new GrpcServerPeerIdentityCallCredentials(expectedPeerUri))
      
      • Accepted Valid Minor: make existing effective4MiB gRPC response ceiling explicit and consistent in stub/codec, preserving all owner authentication/selector checks; no speculative limit expansion.
    3. Rewrite the 2026-10-18 entry in the required entry format.Minor

      The file defines one entry format: a ` - YYYY-MM-DD: short title bullet with Context, Observation and Expected pattern sub-bullets. The two other new entries (lines 143–147 and 156–161) follow that format. This entry uses a ## 2026-10-18 — ... heading and free prose instead. The entry is harder to scan, and it breaks the dated append-only list that tooling and stewardship reviews depend on. Keep the recovery-status text in a Recovery` sub-bullet, as the 2026-10-17 entry does.

      📝 Proposed restructure

      -
      -## 2026-10-18 — PR retarget can fail exact merge-parent metadata checks
      -
      -After #3237 merged and #3246 was retargeted to `develop`, Runtime Images run `39093729815` and Preview run `39093729854` rejected ...
      -
      -Gameplay reported the captured failures to Overseer ... replacement CI has not yet established recovery.
      +- `2026-10-18`: PR retarget can fail exact merge-parent metadata checks
      +  - Context: After #3237 merged and #3246 was retargeted to `develop`, Runtime Images run `39093729815` and Preview run `39093729854` checked the retargeted head/base pair.
      +  - Observation: Both runs rejected the selected test-merge commit because it lacked its exact parents. Runtime failed before image production; Preview exhausted five merge-computation attempts. The PR Runtime path uses `GITHUB_SHA`; an empty dispatch-only `EVENT_MERGE_SHA` is not the cause. The cause is unconfirmed.
      +  - Expected pattern: Treat green runs on the previous parent as not qualifying a retargeted pair. Do not weaken the guard or rerun blindly.
      +  - Recovery: Reported to Overseer in controller message `64512c73-9fa2-44b5-b2b7-e5b607155777` (Preview evidence in reply `0de28b96-8790-4e5e-b8e5-a915d96de829`). Parent reconciliation and the required correction push are the next recovery boundary; replacement CI has not yet established recovery.
      

      As per coding guidelines, ai-observations.md defines "Entry format: - YYYY-MM-DD: short title / Context / Observation / Expected pattern", and AGENTS.md requires "append dated entries".

      • Accepted Valid Minor: own new retarget observation violates established dated bullet format. Preserve all incident facts/recovery unknowns in canonical entry fields.
    4. Reconcile the conflicting Game Design gate results in the selected-template section.Minor

      The same section reports results that cannot all be current:

      • Line 59 says the 3ad94e6c… gate passed 624 units and 170 native cases. It also says this result "supersedes the earlier Game Design endpoint gap".
      • Line 69 says "Game Design's 616 units retain R17". It reports that R21 failed with six Game Design native failures and that "full-native qualification remains held".
      • The world-runtime tracker (world-runtime-and-movement.md line 11) says "all Game Design native cases skip after Docker discovery fails". That statement also conflicts with line 59.

      A reader cannot tell whether Game Design native qualification is complete or held, or which unit count applies. Pick the latest source attribution as the current statement. Label the R17/R21/R22 results explicitly as earlier-source history, or remove them. Update world-runtime line 11 in the same change.

      As per path instructions, "Review docs for canonical-current-state consistency. Flag obsolete transitional guidance". The tracker README requires keeping "status, implementation record, validation, gaps … sections aligned".

      Also applies to: 69-69

      • Accepted Valid Minor: older GDS skipped/failed gate narratives conflict with later qualified3ad source. Separate historical failed attribution from later passing source and current focused-only proof.
  7. CLI Review 4 CompletedRuntime 3m 54s
    Found: 4 Accepted: 0/2/2 Routed: 0
    1. Add the new prepared RPCs to the gRPC API index.Minor

      This change adds three standalone Game Design RPC surfaces:

      • GameDesignAuthoredInitialActorCoreReadService.ReadAuthoredInitialActorCore (protos/game-design/v1/authored_initial_actor_core_read.proto).
      • The StartSession template-association read.
      • The StartSession launch-descriptor resolve.

      Implementation Status mentions only the association read. The ## gRPC APIs index and the ### gRPC list have no entries for any of these RPCs. They also do not record the peer allowlist for the authored-core read, which is Game Session or Entity. Line 161 of this document requires the proto contract and these sections to change together.

      Add one index entry for each RPC. Mark each entry as standalone and unregistered. Record its exact peer allowlist and its bounds. The authored-core bounds are a 128 KiB request and a 16 MiB response, with an 8 MiB canonical result.

      • Accepted Verified new standalone authored-core/StartSession RPCs are absent from both API indexes. Record implemented peer/bound constraints and unregistered status at canonical API owner, without new authority or invented limits.
    2. Add focused tests for the release-to-frozen-graph binding checks.Trivial

      requireExactReleaseGraph and actualSelectorEvidence decide whether frozen World data matches the authenticated Game Design release. These checks include the participant scope, commit, content digest, digest schema, selector request, start ROOM and receipt binding digest.

      WorldPublishedSpawnRequirementsReadOwnerTest reaches only the steps before these checks or the status() rejection. No test runs read() through requireExactReleaseGraph on a success path. No test changes one bound field and expects FAILED_PRECONDITION.

      The outer catch (RuntimeException) at Line 125 turns every mismatch into the same FAILED_PRECONDITION. A regression that removes a single comparison would therefore not fail any current test.

      Add these tests:

      • One test where read() returns evidence from an exact match.
      • Parameterized tests that change one field each, for example world.contentDigest(), freeze.appliedCommitId(), receipt.bindingDigest() and the start-ROOM count. Each test must expect FAILED_PRECONDITION.

      The path instructions require it: "Prioritize bugs, regressions, missing tests, cross-service contract drift".

      • Accepted Current owner tests exit before requireExactReleaseGraph/actualSelectorEvidence or test projection alone. Add exact success plus independently varied immutable binding refusals in existing test file.
    3. Map a failure to begin the snapshot transaction to UNAVAILABLE.Minor

      snapshot.execute(...) calls PlatformTransactionManager.getTransaction before the callback runs. Assume the database is unreachable or the connection pool is exhausted. Then DataSourceTransactionManager throws CannotCreateTransactionException. That exception is a TransactionException, not a DataAccessException. Neither the jOOQ catch nor the Spring DataAccessException catches it. The final catch (RuntimeException invalid) then reports it as FAILED_PRECONDITION with "Exact StartSession template association is unavailable or conflicting".

      Callers treat FAILED_PRECONDITION as a conflict, so they do not retry. The Game Session and the authored-core read callers receive a conflict for a temporary outage. A TransactionSystemException during the read-only commit takes the same path. The path instructions require correct gRPC application-error handling and failure-mode mapping.

      🛠️ Proposed fix

           } catch (org.springframework.dao.TransientDataAccessException
               | org.springframework.dao.DataAccessResourceFailureException unavailable) {
             throw Status.UNAVAILABLE
                 .withDescription("Game Design association owner storage unavailable")
                 .withCause(unavailable)
                 .asRuntimeException();
      +    } catch (org.springframework.transaction.CannotCreateTransactionException
      +        | org.springframework.transaction.TransactionSystemException unavailable) {
      +      throw Status.UNAVAILABLE
      +          .withDescription("Game Design association owner storage unavailable")
      +          .withCause(unavailable)
      +          .asRuntimeException();
           } catch (RuntimeException invalid) {
      

      As per path instructions: "Flag changes that violate documented FireMUD invariants, especially gRPC application-error handling, ownership boundaries, and failure-mode expectations."

      • Accepted Verified Spring CannotCreateTransactionException and TransactionSystemException fall through to permanent FAILED_PRECONDITION. Map these storage lifecycle failures to existing sanitized UNAVAILABLE and test begin/completion.
    4. Reuse the existing launch-descriptor encoder.Trivial

      toCompleteLaunchBindingResponse builds the AuthoredWorldLaunchDescriptorEvidence protobuf and the LaunchDescriptor message field by field. That is about 60 lines. AuthoredWorldLaunchDescriptorGrpcCodec.toLaunchDescriptorMessage(descriptor) already does this encoding, and AuthoredInitialActorCoreReadEvidence uses it.

      The copy must track every future descriptor field. If a new optional field is added to the shared codec and not here, the round-trip check at Line 299 fails. Each spawn read then fails with "Encoded complete launch binding differs from its immutable evidence pair", and no compile-time signal shows the cause.

      Delegate to the shared encoder and keep the round-trip check.

      ♻️ Proposed refactor

         public static GetCompleteLaunchBindingResponse toCompleteLaunchBindingResponse(
             GetLaunchDescriptorRequest request, CompleteLaunchBindingEvidence evidence) {
           Objects.requireNonNull(request, "request");
           Objects.requireNonNull(evidence, "evidence");
      -    AuthoredWorldLaunchDescriptorEvidence descriptor = evidence.descriptor();
      -    var bindingBuilder = ...
      -    ...
      -    var descriptorBuilder = ...
      -    ...
           GetCompleteLaunchBindingResponse response =
               GetCompleteLaunchBindingResponse.newBuilder()
                   .setRequestId(request.getRequestId())
      -            .setLaunchDescriptor(descriptorBuilder)
      +            .setLaunchDescriptor(
      +                AuthoredWorldLaunchDescriptorGrpcCodec.toLaunchDescriptorMessage(
      +                    evidence.descriptor()))
                   .setReleaseAttestation(
      
      • Accepted Verified existing canonical encoder covers the same descriptor fields and optional values. Delegate duplicate encoding and retain exact round-trip check to remove drift risk without wire changes.
  8. CLI Review 5 CompletedRuntime 2m 57s
    Found: 3 Accepted: 0/0/2 Routed: 0
    1. Map tuple decode failures to INVALIDARGUMENT instead of UNAVAILABLE.Minor

      Map tuple decode failures to `INVALID_ARGUMENT` instead of `UNAVAILABLE`.

      The class Javadoc says the typed request is untrusted. In this block, request.decodedTuple() runs inside the same try as the Account projection call. If the tuple bytes do not decode, the method throws a non-Status RuntimeException. The catch (RuntimeException unavailableOrInvalid) branch then reports UNAVAILABLE with "Exact redeemed StartSession projection unavailable".

      Callers normally retry UNAVAILABLE. A malformed request can therefore enter a retry loop that cannot succeed. The error also reports a dependency outage that did not happen. Keep the UNAVAILABLE mapping only for the Account projection call. Decode the tuple first in its own block.

      🐛 Proposed fix

           final StartSessionPostAuthorizationExecutionTuple tuple;
           try {
             tuple = request.decodedTuple();
      +    } catch (RuntimeException malformed) {
      +      throw Status.INVALID_ARGUMENT
      +          .withDescription("Malformed StartSession post-authorization tuple")
      +          .withCause(malformed)
      +          .asRuntimeException();
      +    }
      +    try {
             requireAuthorizedTarget(request, tuple);
             ReadRedeemedOperationProjectionResponse projection =
                 accountProjectionReader.read(tuple, request.ownerAttemptId(), request.ownerFence());
      

      Check whether StartSessionTemplateAssociationReadGrpcCodec.fromRequest or the Request constructor already rejects tuple bytes that do not decode. If either one does, the malformed-input path is unreachable from the gRPC adapters. Direct callers of the public read(...) can still reach it.

      As per path instructions: "Flag changes that violate documented FireMUD invariants, especially gRPC application-error handling".

      • Rejected Unreachable malformed typed request: Request constructor decodes and canonical-compares tuple bytes, then stores a private clone and returns clones. Record is final. Direct callers cannot supply undecodable bytes; gRPC codec invokes same constructor.
    2. Add coverage for non-empty projection correlation.Trivial

      Fixture.result() always passes List.of() as projections. As a result, no test reaches the projection checks in ReadResult.requirePublicCorrelation. Those checks cover duplicate bindingId and mismatches in worldSourceOperationId, worldSourceEvidenceDigest, worldSlug, publicationWorkflowId, canonical tenant, canonical Version, and selected commit. They also determine the ordered projection list in encodeCanonical. These checks are the main integrity boundary for this read.

      Add one positive case with at least one matching AuthoredInitialActorCoreProjection. Add negative cases for a duplicate binding and for one mismatched correlation field. Add a codec round-trip that keeps projection order.

      • Accepted Useful missing integrity proof: current fixture always has zero projections. Add matching nonempty projection, duplicate-binding and mismatched-correlation rejection, plus ordered codec roundtrip in existing owning tests.
    3. Replace the unchecked DescriptorOutcome cast with a typed check.Trivial

      fromResponse casts resolved.outcome() to StartSessionLaunchDescriptorGrpcCodec.DescriptorOutcome without an instanceof check. If the decoded outcome is ever a failure outcome, the cast throws ClassCastException. GrpcAuthoredInitialActorCoreReadClient.read catches only IllegalArgumentException. A ClassCastException would therefore skip the client's "invalid authored-core evidence" mapping and escape as a raw runtime error. The read still fails closed, but the error contract becomes inconsistent. Throw IllegalArgumentException explicitly.

      ♻️ Proposed refactor

      -    var descriptor =
      -        ((StartSessionLaunchDescriptorGrpcCodec.DescriptorOutcome) resolved.outcome()).descriptor();
      +    if (!(resolved.outcome()
      +        instanceof StartSessionLaunchDescriptorGrpcCodec.DescriptorOutcome descriptorOutcome)) {
      +      throw new IllegalArgumentException("Authored-core read requires a successful descriptor");
      +    }
      +    var descriptor = descriptorOutcome.descriptor();
      
      • Accepted Accept explicit typed success-outcome invariant at authored-core boundary. Current descriptor-only envelope already ensures success; checked extraction clarifies rejection contract without claiming a currently reachable ClassCastException.
  9. CLI Review 6 CompletedRuntime 2m 45s
    Found: 2 Accepted: 0/1/1 Routed: 0
    1. Use the documented Context field for location, not instruction.Trivial

      The file defines Context as "where it appeared". In this entry, the Context line gives a directive ("Before relying on filtered readback ... account for ..."). It does not name the lane, PR or test where the counterexample appeared. The entry therefore mixes Context with Expected pattern. Move the directive into Expected pattern. State the template repository update path and the native test that exposed the cross-tenant rewrite in Context.

      📝 Proposed wording

      -  - Context: Before relying on filtered readback or later owner guards, account for the template repository's global-ID update, which could rewrite a retained row's tenant before returning it under the supplied tenant; a tenant-filtered readback did not protect the original row.
      +  - Context: Game Design template repository update proof (`GameTemplateRepositoryPostgresIntegrationTest`) on the template create/update correction lane.
      +  - Observation: The global-ID update could rewrite a retained row's tenant before the tenant-filtered readback returned it, so the readback did not protect the original row. The native counterexample changed the complete row and `xmin`, while the restored exact tenant predicate preserves both owner rows and their versions.
      

      As per coding guidelines, the AI observations entry format says "Context: where it appeared".

      • Accepted Valid small observation-format improvement: Context should name template update path/native counterexample. Preserve changed row/xmin/predicate facts in Observation and guidance in Expected pattern.
    2. The 128 KiB request bound does not limit transport buffering.Minor

      request.getSerializedSize() runs after gRPC has already received, buffered and parsed the complete message. The server's maxInboundMessageSize is the only limit at that stage, and the gRPC default is 4 MiB. The check therefore rejects oversized requests only after the read cost is paid. It does not enforce the "request is capped at 128 KiB wire size" contract in api-contracts.md lines 133 and 221.

      The Draft terminal-read adapter documents the same situation as a registration hold: "future server composition must admit the bounded request before this currently unregistered adapter is enabled". Record the same hold for this adapter. When the adapter is registered, configure the inbound size limit for this service at 128 KiB on the receiving server composition. Keep the in-handler check as defense in depth.

      • Accepted Valid registration-hold clarification: handler serialized-size rejection occurs after buffering. Keep adapter unregistered and handler guard; document future receiving composition128KiB enforcement, without enabling server or changing limits.

Routed Findings

0 Open0 Accepted/Fixed0 Rejected

No routes recorded

Unlinked items

no items unlinked