Skip to content

Implement final-review fixes for unique migrated goal binding, resolved actor-session public API, and fail-closed executor evidence validation. Preserve ActorSessionLease's exact two public fields and #5007

Description

@rysweet

Task Description

Implement final-review fixes for unique migrated goal binding, resolved actor-session public API, and fail-closed executor evidence validation. Preserve ActorSessionLease's exact two public fields and register_actor_session source compatibility. Add behavioral tests. Do not modify documentation, do not commit, do not push, and do not create or update issues or pull requests; use apply_patch for every code or test edit. Run the exact requested validation commands with NODE_OPTIONS=--max-old-space-size=32768 and unset SIMARD_OBSERVE_ONLY where mutation tests require it.

Requirements

No blocking ambiguity remains. Final design requirements:

  1. Enforce exactly one authoritative actor-session binding per migrated goal. Reject duplicate or conflicting bindings explicitly; never overwrite, select, or ignore them.
  2. During schema migration, detect pre-existing collisions and fail deterministically rather than choosing a winner.
  3. Publicly expose the resolved actor-session registration result and ensure consumers use its canonical persisted session identity.
  4. Keep ActorSessionLease unchanged with exactly two public fields: token and expires_at_unix_millis.
  5. Preserve the existing register_actor_session signature, call patterns, compilation compatibility, and behavior.
  6. Reject operations requiring actor-session resolution when no valid persisted session can be resolved.
  7. Fail closed whenever executor evidence is required. Before authorization/dispatch and successful completion, positively verify authenticity and all effect, outcome, action payload, repository, session, cycle, goal, and policy bindings.
  8. Treat missing, malformed, tampered, mismatched, ambiguous, stale, or unverifiable evidence as rejection. Preserve existing behavior for non-privileged operations where evidence is not required.
  9. Add behavioral tests for valid execution, duplicate and conflicting migrated-goal bindings, unresolved sessions, registration compatibility, lease field shape, and absent or invalid executor evidence.
  10. Modify only relevant code and tests using apply_patch. Do not change documentation or perform commits, pushes, issue updates, or pull-request operations.
  11. Run each subsequently supplied validation command exactly with NODE_OPTIONS=--max-old-space-size=32768; unset SIMARD_OBSERVE_ONLY for mutation-test commands. The command list is an execution-stage input, not a design ambiguity.

Acceptance Criteria

  • All explicit requirements met
  • Tests passing
  • Philosophy compliant
  • Documentation updated

Classification

Generated via default-workflow recipe

Metadata

Metadata

Assignees

No one assigned

    Labels

    workflow:defaultCreated by default-workflow recipe

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions