Skip to content

Extend Keystone's Action base and a CortexException root - #12

Merged
jayjfletcher merged 1 commit into
ringside-migrationfrom
keystone-actions-and-exceptions
Oct 27, 2026
Merged

jayjfletcher merged 1 commit into
ringside-migrationfrom
keystone-actions-and-exceptions

Conversation

@jayjfletcher

Copy link
Copy Markdown
Member

Stacked on #11 (Ringside migration); retarget to main once that merges.

  • Every action extends RefactorCircus\Keystone\Actions\Action: callers keep execute(), each action implements a protected handle().
  • Every exception descends from the abstract RefactorCircus\Cortex\Exceptions\CortexException (on Keystone's PackageException). New InvalidAgentClassException, InvalidToolClassException, InvalidMcpServerClassException, ImmutableVersionException and UnexpectedResultException replace raw SPL throws.
  • tests/ArchTest.php checks both rules.
  • The work predates the ConcreteServer rename (#9: Virtual and concrete MCP servers (concrete servers: rename and tool override) #10) and was ported onto it, including the new ClearConcreteServerToolsAction and UpdateConcreteServerToolsAction.

Locally: phpstan clean; Pest 655/656. The one failure, KeenInCiTest "keeps refactor-circus/keen in require-dev with a lock entry", reads the untracked composer.lock, which is stale in a composer.local.json install; CI builds a fresh one.

🤖 Generated with Claude Code

Every action now extends RefactorCircus\Keystone\Actions\Action: callers
keep execute(), each action implements a protected handle(). Every
exception descends from the abstract CortexException (on Keystone's
PackageException), with new Invalid{Agent,Tool,McpServer}ClassException,
ImmutableVersionException and UnexpectedResultException replacing raw
SPL throws. ArchTest checks both.

Ported onto the ConcreteServer rename, including its new tool-override
actions.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@jayjfletcher
jayjfletcher merged commit acc27ac into ringside-migration Oct 27, 2026
4 checks passed
@jayjfletcher
jayjfletcher deleted the keystone-actions-and-exceptions branch October 27, 2026 04:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant