FireMUD Delivery Status

PR data refreshed

PR #3145 review history

Review rounds

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

Hosted CodeRabbit2 completed
3/3/01/1/0
CLI CodeRabbit2 completed
2/1/02/2/0
Subagent Review2 completed
2/2/01/1/0

Recorded review history

Reviews and findings

  1. CLI Review 1 CompletedRuntime 2m 12s
    Found: 2 Accepted: 0/1/0 Routed: 0
    1. The claim-path descriptor INSERT does not check the original authorization expiry.Minor

      The two pin overloads have different checks:

      • pin(EvidenceContinuation, …) adds ?::timestamptz > clock_timestamp(). The bound value is authorizationExpiresAt.
      • pin(AttemptClaim, …) checks only attempt.lease_expires_at > clock_timestamp().

      The owner lease can be up to five minutes. It is independent of the Account reference expiry. A claim whose Account reference has already expired can therefore still persist an immutable descriptor pin while the lease is live.

      That contradicts two documents:

      • The tracker claims "database-clock claim/reference-expiry checks at descriptor pinning".
      • The ADR-0048 rule says reconciliation after authorization expiry is read-only.

      Add the same predicate to the claim path. Derive the value from attempt.post_authorization_execution_tuple with the existing originalAuthorizationExpiresAt logic.

      🛡️ Proposed fix

                       + "AND attempt.account_redemption_projection IS NOT NULL "
      +                + "AND ?::timestamptz > clock_timestamp() "
                       + "AND attempt.lease_expires_at > clock_timestamp() "
                       + "RETURNING *",
                   ...
                   claim.claimOwnerId(),
      -            claim.ownerFence());
      +            claim.ownerFence(),
      +            StartSessionAuthorityEvidenceBundle.decode(
      +                    association.result().request().decodedTuple().authorityEvidenceBundleBytes())
      +                .authorizationExpiresAt());
      
      • Accepted Valid #3145-owned fresh descriptor INSERT lacks original Account authorization expiry at DB statement; add independent reference-expiry predicate and race proof, preserving read-only exact replay.
    2. The tracker claims reference-expiry checks at descriptor pinning, but only one pin path has them.Minor

      Line 9 claims "database-clock claim/reference-expiry checks at descriptor pinning". This is true only for GameSessionStartSessionLaunchDescriptorRepository.pin(EvidenceContinuation, …). The pin(AttemptClaim, …) overload checks only lease_expires_at > clock_timestamp(). It does not check the original authorization expiry.

      Choose one of these fixes:

      • Add the reference-expiry predicate to the claim path. This is the preferred fix; see the repository comment.
      • Limit the tracker sentence to the continuation path.

      The coding guidelines require: "Keep its status, implementation record, validation, gaps … aligned".

      • Rejected Duplicate observation of finding1, not a separate obligation. The accepted INSERT/reference-expiry correction makes the tracker claim true; do not weaken the documented invariant.
  2. Hosted Review 1 CompletedRuntime 9m 15s
    Found: 3 Accepted: 0/3/0 Routed: 0
    1. Treat only ambiguous gRPC statuses as ACCOUNT_OUTCOME_AMBIGUOUS.Minor

      The catch (StatusRuntimeException ...) block treats every non-OK status as an ambiguous Account outcome. Some statuses are not ambiguous:

      • UNAUTHENTICATED from GrpcServerPeerIdentityClientInterceptor means the request never reached Account. StartSessionOperatorRedemptionClientMtlsTest proves this with rpcStarts == 0.
      • INVALID_ARGUMENT, PERMISSION_DENIED, and FAILED_PRECONDITION are definitive denials.

      The current code records each of these as ACCOUNT_OUTCOME_AMBIGUOUS. Reconciliation then treats a known "not redeemed" result as "unknown". Classify only DEADLINE_EXCEEDED, UNAVAILABLE, CANCELLED, UNKNOWN, and INTERNAL as ambiguous. Propagate the other statuses, or map them to a distinct non-redeemed outcome.

      Proposed fix

           } catch (StatusRuntimeException ambiguousTransportOutcome) {
      +      if (!isAmbiguous(ambiguousTransportOutcome.getStatus().getCode())) {
      +        throw ambiguousTransportOutcome;
      +      }
             return new AuthorizationResult(
                 reservation.snapshot(), Optional.of(claim), Progress.ACCOUNT_OUTCOME_AMBIGUOUS);
           }
      
        private static boolean isAmbiguous(io.grpc.Status.Code code) {
          return switch (code) {
            case DEADLINE_EXCEEDED, UNAVAILABLE, CANCELLED, UNKNOWN, INTERNAL -> true;
            default -> false;
          };
        }
      
      • Accepted Accepted #3145-owned status classification: preserve ambiguity only for transport/unknown/internal statuses; propagate definitive denials without attachment, redemption retry or terminalizing the pending owner claim.
    2. Add or update the Capability Status row for this boundary.Minor

      This change adds only a narrative record. The tracking guideline requires one Capability Status row for every capability that the tracker primarily owns. For an implemented or partial status, the row must name concrete production anchors. It must also use the No focused executable proof: marker or name focused proof. The PostgreSQL cases were not executed, so focused proof is absent. Possible anchors are GameSessionStartSessionOperatorAttemptRepository, GameSessionStartSessionLaunchDescriptorContinuationService, and the V35/V37/V38 migrations. If another tracker owns this capability, add a handoff link to it instead.

      As per coding guidelines: "Each tracker contains one Capability Status row for every capability it primarily owns" and "An audited, unverified, or not-applicable row may omit executable proof only when its proof cell uses the explicit No focused executable proof: marker".

      • Accepted Partially accepted tracker row: add concrete inactive capability and executable proof anchors; retain exact physical fresh/upgrade PostgreSQL attribution gap without incorrectly claiming all executable proof absent.
    3. Document the descriptor-pin write and the actual lock order.Minor

      The contract text has two inaccuracies:

      • It says the continuation is "restricted to reading and exact replay of an existing immutable association pin". GameSessionStartSessionLaunchDescriptorContinuationService.continueOriginalEvidence also inserts a new game_session_start_session_launch_descriptor_pin row.
      • It says Game Session "then locks and rechecks the same owner state before returning the association". The code first locks and reads the association in one owner transaction. It then makes the Account and Game Design calls outside SQL. Finally it locks again, rechecks, and pins the descriptor.

      Under the path instructions, the architecture document owns the technical target state. The text must match the implemented boundary.

      Proposed wording

      -The continuation is restricted to reading and exact replay of an existing immutable association pin. It must not replay redemption, ... Remote Account/source reads occur outside SQL; Game Session then locks and rechecks the same owner state before returning the association. The actual pin/read statement enforces claim expiry using the database clock.
      +The continuation is restricted to reading and exact replay of an existing immutable association pin and to creating at most one immutable launch-descriptor evidence pin for that exact association. It must not replay redemption, ... Game Session reads the association under the owner lock, performs remote Account and Game Design reads outside SQL, then locks and rechecks the same owner state and association before pinning the descriptor. The descriptor pin statement enforces claim lease and original reference expiry using the database clock.
      
      • Accepted Accepted owner-contract correction: bounded original continuation may create one immutable descriptor evidence pin; document actual lock/remote-read/recheck sequence and unchanged no-admission/no-renewal limits.
  3. Subagent Review 1 CompletedModel: gpt-6-luna · Xhigh
    Found: 2 Accepted: 2 Routed: 0
    1. Initial immutable association INSERT omits current owner lease at statementMinor

      Immutable d539 review: template association pin uses plain VALUES after validateCurrentAttempt. Inactive unregistered scope; no current player admission.

      • Accepted Owned preparation invariant requires same unexpired original claim at pinning; earlier owner lock/validation does not keep wall-clock lease live while INSERT waits. Add exact owner-qualified database-clock INSERT and regression.
    2. Descriptor continuation SELECT omits original owner lease at readMinor

      Immutable d539 review of existing descriptor replay; earlier query validates lease, final descriptor SELECT lacks it. Account reference check alone insufficient.

      • Accepted Owned continuation contract requires actual read under original live claim plus reference expiry; SELECT only checks reference expiry after earlier owner validation. Add exact owner lease/identity at read with blocked-read regression, preserve distinct historical reads.
  4. CLI Review 2 CompletedRuntime 2m 43s
    Found: 2 Accepted: 0/2/0 Routed: 0
    1. Add the original-authorization expiry check to the initial association INSERT … SELECT.Minor

      The initial association pin checks the owner-claim lease (attempt.lease_expires_at > clock_timestamp()). It does not check that the original Account authorization reference is still unexpired. The descriptor pin checks both conditions at its write boundary (?::timestamptz > clock_timestamp() in insertClaimPin and in the continuation INSERT).

      Trigger: Account redemption succeeds. Then the authorization reference expires while the owner claim lease is still live. The caller can still write a new immutable association pin under that claim. ADR-0048 states: "After authorization expiry, reconciliation is read-only." The descriptor path enforces that rule, but the association path does not.

      GameSessionStartSessionLaunchDescriptorRepositoryIntegrationTest.liveOwnerClaimCannotCreateDescriptorPinAfterOriginalAuthorizationExpires depends on this gap. It creates the association pin with an already-expired tuple. After the fix, create the association before the reference expires. Or assert the new rejection in that test.

      🛡️ Proposed fix

                   + "AND attempt.lease_expires_at > clock_timestamp() "
      +            + "AND ?::timestamptz > clock_timestamp() "
                   + "RETURNING *",
               ...
               exactTuple,
      -        exactProjection);
      +        exactProjection,
      +        StartSessionAuthorityEvidenceBundle.decode(
      +                StartSessionPostAuthorizationExecutionTuple.decode(exactTuple)
      +                    .authorityEvidenceBundleBytes())
      +            .authorizationExpiresAt());
      
      • Accepted Verified initial association INSERT only guards original claim lease, unlike descriptor write original authorization expiry; add exact original-reference DB-clock expiry at association write and blocking-wait regression without renewal.
    2. Fix the conflicting AA-2.1 status values.Minor

      The new section is named AA-2.1 and gives proof state audited (Line 13). The AA-2.1 row in the Capability Status table (Line 68) still gives partial / drift-found. Line 27 also says AA-2.1 remains partial / drift-found. One capability ID now has two verification states.

      The AA-2.1 row covers "Gameplay login, character selection, and session binding". The StartSession operator-continuation work is a different control-plane capability. The tracker contract requires one Capability Status row per capability. It also requires that row to name the concrete production anchors. The current row has none of the new coordinator, repository, or migration anchors.

      Use one of these fixes:

      • Change the new section to a sub-record without its own status, and keep partial / drift-found as the only AA-2.1 status.
      • Give the continuation work its own capability ID and row. Put its implementation anchors, proof anchors, and the audited state in that row.

      As per coding guidelines: "Keep its status, implementation record, validation, gaps, decisions, and service-map sections aligned" and "Each tracker contains one Capability Status row for every capability it primarily owns."

      • Accepted Verified new AA-2.1 sub-boundary says audited while capability status remains partial/drift-found; preserve canonical capability row and express preparation audit as bounded sub-record proof, not second capability status.
  5. Hosted Review 2 CompletedRuntime 5m 21s
    Found: 1 Accepted: 0/1/0 Routed: 0
    1. Make the initial association pin check that the original authorization has not expired, using the database clock.Minor

      The INSERT ... SELECT in insertInitialPin checks the owner claim lease (lease_expires_at > clock_timestamp()). It does not check when the original Account authorization reference expires. The owner claim lease can last up to five minutes, and the authorization reference can expire while the claim is still live. In that state, this path still creates the immutable association pin.

      The descriptor claim path rejects the same state. GameSessionStartSessionLaunchDescriptorRepository.insertClaimPin binds ?::timestamptz > clock_timestamp() at the write. The test liveOwnerClaimCannotCreateDescriptorPinAfterOriginalAuthorizationExpires asserts that behavior. The continuation path also checks the expiry through requireOriginalAuthorityUnexpired. Without the same predicate here, an expired authorization can still create the first association evidence.

      To fix this, decode the stored tuple's authorizationExpiresAt() and add the same predicate to the insert statement.

      🛡️ Proposed fix

                   + "AND attempt.account_redemption_projection = ? "
                   + "AND attempt.lease_expires_at > clock_timestamp() "
      +            + "AND ?::timestamptz > clock_timestamp() "
                   + "RETURNING *",
      @@
               exactTuple,
      -        exactProjection);
      +        exactProjection,
      +        net.firedevops.firemud.common.operator.StartSessionAuthorityEvidenceBundle.decode(
      +                StartSessionPostAuthorizationExecutionTuple.decode(exactTuple)
      +                    .authorityEvidenceBundleBytes())
      +            .authorizationExpiresAt());
      

      Add bindings[25] to GameSessionStartSessionTemplateAssociationRepositoryTest. Also add an integration case: a claim that is still live but carries an expired original reference must not create an association pin.

      • Accepted Verified original authorization expiry absent in initial association INSERT while lease remains live; same current-PR obligation as accepted CLI04e883 finding1, addressed once withDB-clock writepredicate and regressionproof.
  6. Subagent Review 2 CompletedModel: gpt-6-luna · Xhigh
    Found: 1 Accepted: 1 Routed: 0
    1. Initial association must reject expired original authorizationMinor

      One combined reviewer candidate: initial association write is useful and accepted. Descriptor existing-result read/replay portion is not a separate obligation: it does not create a new pin or authority; fresh descriptor INSERT and opaque evidence continuation enforce reference expiry.

      • Accepted Initial INSERT lacked DB-clock reference expiry; duplicates accepted CLI1 and Hosted4237098583. Same fix batch. AttemptClaim retained reads/replays are non-authorizing reconciliation; restricted EvidenceContinuation separately enforces expiry.

Routed Findings

0 Open0 Accepted/Fixed0 Rejected

No routes recorded

Unlinked items

no items unlinked