Skip to content

Permission strategies - #79

Open
moshloop wants to merge 19 commits into
mainfrom
permission-strategies
Open

Permission strategies#79
moshloop wants to merge 19 commits into
mainfrom
permission-strategies

Conversation

@moshloop

Copy link
Copy Markdown
Member

No description provided.

…port

Introduce durable token enrollment, HTTPS mailbox and sidecar transport, and hardened Docker/Kubernetes deployment with address preflight and lifecycle controls.
Persist remote task history and expose sandbox catalogs, credential publishing, deployment management, and runtime inspection through the API and web UI.
BREAKING CHANGE: replace single-use git-agent join-token APIs and replay semantics with durable captain tokens; callers must use AdmitToken and context-aware enrollment.
…ions

Add opt-in mirroring for Claude and Codex subscription logins with refresh-token redaction and expiry tracking.
Publish credentials atomically to host directories or Kubernetes Secrets, refresh them from `serve`, and expose local-only status and sync controls.
Wire acquired logins through sandbox isolation while centralizing token-provider selection and resolving model credentials from the Captain vault.
…n access

Protect off-host API and git-agent requests with durable, revocable bearer tokens while preserving loopback access for the local UI and CLI.
Add TLS certificate management and local-only command registration to prevent host-administering commands from being exposed through the REST executor.
Persist hashed credentials with scoped, bound or pooled identities, expiry, revocation, and usage tracking.

BREAKING CHANGE: Non-loopback requests to /api/v1 and /git now require a valid scoped Captain bearer token provisioned with `captain token create`.
Allow non-streaming workflow providers to satisfy the runner's event contract via buffered execution instead of failing. Add coverage for completed text and result events.
Every other configurable axis — model, effort, cliArgs, sandbox — is declared
in the registry, served to clients, and guarded server-side. Permissions had
none of that: any posture or per-tool policy could be written for any backend,
and the mismatch surfaced only when a provider built argv, minutes into a run.

Declare what each backend actually does with a permissions block: which
postures it honours (native, approximated, or not at all, plus the argv or
sandbox/approval pair each compiles to), which per-tool policies it can
enforce, and which resources it can switch. Project it through RuntimeModeEntry
and backends[] so clients read it from the static catalog rather than from a
TTL-d probe, where an unprobed backend would appear to support nothing.

Tool-policy capability is keyed by provenance, not by backend alone, because
where a tool came from decides what is enforceable. Captain builds the
caller-tool list itself and omits a denied tool, so deny is honoured on
codex-agent — which has no tool filter of its own — while deny on a codex
built-in is not.

Resources are keyed by the value requested as well as the kind: MCP is only
switchable off and skills only on, so one cell per kind would report
"supported" for a request that is accepted and dropped.

The table states what the code does today, warts included, and the tests prove
it against CodexSafety, the three CLI arg builders, the cmux command builder
and the claude-agent initialize params, so a mapper and its declaration cannot
drift apart in silence.

Claude-Session-Id: c3c29851-27f6-4cce-831d-ca61a67461d4
Tools and MCP carry every field as json:"-" behind hand-written marshalers, so
reflection reported {} for both — the two fields that decide what an agent may
do validated anything at all and told a client nothing. The permission enums
are plain string types, so they reflected to a bare string with no values,
which is why the editor grew its own hardcoded copies that then went stale.

Add invopop describers for PermissionMode, ToolPolicy, ResourceMode, Preset,
Tools, MCP and ResourcePolicies. ResourcePolicies also declares the legacy
string-array form it has always decoded, so a document using it no longer
fails validation against captain's own schema.

pkg/api hosts both invopop and clicky describer signatures and a type given
the wrong one is silently ignored; the rule is the consumer, so anything
reachable from api.Spec uses invopop.

Claude-Session-Id: c3c29851-27f6-4cce-831d-ca61a67461d4
Print the declared capability table so a silent drop is visible before a run is
spent on it. Settings x backends, grouped one table per agent family: eleven
backend names do not fit a terminal, and truncating them collapses claude-cli
and claude-cmux into the same ambiguous header. Grouping also matches the
question people actually ask — I picked claude, which transport honours this?

Approximated cells get their own mark rather than rounding to yes or no; that
conflation is what let dontAsk read as supported on codex, where it resolves to
the read-only default. --notes prints the reason attached to every cell that is
not honoured exactly.

A separate namespace from sandbox presets, which already owns that word for
container presets. Deliberately not excluded from REST/MCP auto-exposure: it
reads a compile-time table and touches no host state. local_only_test pins
POST /api/v1/permissions/matrix as the group's only route so a future mutating
command cannot slip in beside it.

The gavel fixture is the second pinning mechanism: 44 cases over the printed
grid and the JSON, so a change to what captain does with a permissions block
has to arrive as a reviewable diff to the declared truth.

Claude-Session-Id: c3c29851-27f6-4cce-831d-ca61a67461d4
Claude-Session-Id: a317c3d6-1ab9-47ea-8118-4897be0ec96c
Runs that only touch git-ignored paths (scratch dirs) no longer fail over
the caller's unrelated dirty files. committable() filters ignored paths; the
refusal error lists only committable paths, improving diagnostic accuracy.
…ations

Carry the clicky RPCOperation whole on ToolInfo/ToolDefinition instead of flattening entity, verb, scope, method and path into a clicky/* annotation map that three call sites parsed back into typed fields. The key names no longer live twice, once as constants here and once as literals in clicky.

Add PermissionStrategy with HTTPVerbStrategy and MCPHintStrategy — the first implementation of the ordered policy in #61. Authority resolves weakest to strongest: what a tool's own facts imply, what its author registered, then an operator's rules. At every layer 'auto' defers to the layer below rather than overriding it, so a rule can hand a tool back to its hints instead of being ignored.

serve_chat's isReadOnlyCaptainTool becomes captainReadOnlyStrategy, declared in the chain where captain hands its command tree over, and ResolveOptions.Strategies threads it through the chat service.
@coderabbitai

coderabbitai Bot commented Aug 23, 2026

Copy link
Copy Markdown

Important

Review skipped

Too many files!

This PR contains 273 files, which is 173 over the limit of 100.

To get a review, reduce the PR to 100 files or fewer by splitting it into smaller PRs or changing its base branch.

Upgrade to a paid plan to raise the limit.

This review couldn't start because sufficient usage credits or metered capacity aren't available. Add credits or update usage-based reviews in the billing tab, then retry.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: cd02ed7c-fc09-4a53-8899-19c5da232d43

📥 Commits

Reviewing files that changed from the base of the PR and between 1712d6c and 17bf586.

⛔ Files ignored due to path filters (4)
  • go.sum is excluded by !**/*.sum
  • pkg/cli/webapp/dist/.gitkeep is excluded by !**/dist/**
  • pkg/cli/webapp/dist/index.html is excluded by !**/dist/**
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (273)
  • README.md
  • Taskfile.yaml
  • cmd/captain/help.go
  • cmd/captain/help_test.go
  • cmd/captain/internal/rootcmd/help.go
  • cmd/captain/internal/rootcmd/version.go
  • cmd/captain/local_only_test.go
  • cmd/captain/main.go
  • cmd/captain/standalone_test.go
  • cmd/captain/version_test.go
  • docs/astro.config.mjs
  • docs/package.json
  • docs/pnpm-workspace.yaml
  • docs/src/components/RuntimeSpecDemo.tsx
  • docs/src/layouts/DocsLayout.astro
  • go.mod
  • migrations/00_types.pg.hcl
  • migrations/35_git_agent.pg.hcl
  • migrations/36_api_tokens.pg.hcl
  • migrations/git_agent_schema_integration_test.go
  • migrations/migrations_test.go
  • package.json
  • pkg/agentcreds/agentcreds.go
  • pkg/agentcreds/agentcreds_suite_test.go
  • pkg/agentcreds/expiry.go
  • pkg/agentcreds/redact.go
  • pkg/agentcreds/redact_test.go
  • pkg/agentcreds/source.go
  • pkg/ai/agent/commit/commit.go
  • pkg/ai/agent/commit/git.go
  • pkg/ai/agent/commit/stage_test.go
  • pkg/ai/agent/runner.go
  • pkg/ai/agent/runner_timeout_test.go
  • pkg/ai/callertools/credential_ginkgo_test.go
  • pkg/ai/callertools/runtime.go
  • pkg/ai/callertools/runtime_ginkgo_test.go
  • pkg/ai/prompt/prompt_test.go
  • pkg/ai/prompt/testdata/options.prompt
  • pkg/ai/provider/caller_tools_ginkgo_test.go
  • pkg/ai/provider/claude_cli_test.go
  • pkg/ai/provider/claudeagent/caller_tools.go
  • pkg/ai/provider/claudeagent/caller_tools_ginkgo_test.go
  • pkg/ai/provider/claudeagent/permission_capabilities_test.go
  • pkg/ai/provider/claudeagent/permissions_test.go
  • pkg/ai/provider/claudeagent/provider.go
  • pkg/ai/provider/cmux/permission_capabilities_test.go
  • pkg/ai/provider/codex_appserver.go
  • pkg/ai/provider/genkit/options.go
  • pkg/ai/provider/genkit/tool_approval_ginkgo_test.go
  • pkg/ai/provider/genkit/tool_lifecycle_ginkgo_test.go
  • pkg/ai/provider/genkit/tool_preferences_ginkgo_test.go
  • pkg/ai/provider/genkit/tools.go
  • pkg/ai/provider/genkit/tools_test.go
  • pkg/ai/provider/permission_capabilities_test.go
  • pkg/ai/tools/catalog.go
  • pkg/ai/tools/definitions_ginkgo_test.go
  • pkg/ai/tools/preferences_ginkgo_test.go
  • pkg/ai/tools/strategies_ginkgo_test.go
  • pkg/ai/tools/tools.go
  • pkg/aichat/aimock_lifecycle_integration_test.go
  • pkg/aichat/approval_execution.go
  • pkg/aichat/database_threads_integration_test.go
  • pkg/aichat/execution_authority_ginkgo_test.go
  • pkg/aichat/execution_database.go
  • pkg/aichat/execution_database_integration_test.go
  • pkg/aichat/mcp_provider.go
  • pkg/aichat/messages.go
  • pkg/aichat/messages_model_ginkgo_test.go
  • pkg/aichat/runtime_profile.go
  • pkg/aichat/service.go
  • pkg/aichat/service_ginkgo_test.go
  • pkg/aichat/session_title.go
  • pkg/aichat/session_title_ginkgo_test.go
  • pkg/aichat/wire_ginkgo_test.go
  • pkg/api/aliases.go
  • pkg/api/budget.go
  • pkg/api/enums.go
  • pkg/api/is_empty_test.go
  • pkg/api/permission_capabilities.go
  • pkg/api/permission_capabilities_ginkgo_test.go
  • pkg/api/permissions.go
  • pkg/api/permissions_schema.go
  • pkg/api/permissions_schema_test.go
  • pkg/api/permissions_test.go
  • pkg/api/pretty.go
  • pkg/api/registry/backend.go
  • pkg/api/runtime_catalog.go
  • pkg/api/spec.go
  • pkg/api/spec_marshal_ginkgo_test.go
  • pkg/api/spec_merge_differential_test.go
  • pkg/api/spec_test.go
  • pkg/api/tool_policy_support_test.go
  • pkg/api/tool_preferences_ginkgo_test.go
  • pkg/api/toolcatalog.go
  • pkg/api/toolcatalog_ginkgo_test.go
  • pkg/api/tooldef.go
  • pkg/api/toolpolicy.go
  • pkg/api/toolpolicy_ginkgo_test.go
  • pkg/api/toolstrategy.go
  • pkg/api/toolstrategy_ginkgo_test.go
  • pkg/captainconfig/config.go
  • pkg/captainconfig/credentials.go
  • pkg/captaintoken/hash.go
  • pkg/captaintoken/token.go
  • pkg/captaintoken/token_test.go
  • pkg/captaintoken/verify.go
  • pkg/captaintoken/verify_test.go
  • pkg/cli/ai.go
  • pkg/cli/ai_models.go
  • pkg/cli/ai_models_ginkgo_test.go
  • pkg/cli/ai_models_test.go
  • pkg/cli/ai_prompt_file.go
  • pkg/cli/ai_test.go
  • pkg/cli/container_interactive.go
  • pkg/cli/db_context_http.go
  • pkg/cli/gitagent.go
  • pkg/cli/gitagent_agent_api_ginkgo_test.go
  • pkg/cli/gitagent_credentials.go
  • pkg/cli/gitagent_credentials_test.go
  • pkg/cli/gitagent_deploy.go
  • pkg/cli/gitagent_deploy_credentials_test.go
  • pkg/cli/gitagent_deploy_detect.go
  • pkg/cli/gitagent_deploy_detect_test.go
  • pkg/cli/gitagent_deploy_ingress.go
  • pkg/cli/gitagent_deploy_ingress_test.go
  • pkg/cli/gitagent_deploy_reach.go
  • pkg/cli/gitagent_deploy_reach_test.go
  • pkg/cli/gitagent_deploy_run.go
  • pkg/cli/gitagent_deploy_test.go
  • pkg/cli/gitagent_deployment_edit_ginkgo_test.go
  • pkg/cli/gitagent_deployments.go
  • pkg/cli/gitagent_directory.go
  • pkg/cli/gitagent_directory_test.go
  • pkg/cli/gitagent_e2e_test.go
  • pkg/cli/gitagent_hook.go
  • pkg/cli/gitagent_mailbox_record.go
  • pkg/cli/gitagent_restart_ginkgo_test.go
  • pkg/cli/gitagent_serve.go
  • pkg/cli/gitagent_serve_https.go
  • pkg/cli/gitagent_serve_options.go
  • pkg/cli/gitagent_serve_test.go
  • pkg/cli/gitagent_test.go
  • pkg/cli/gitagent_undeploy.go
  • pkg/cli/permissions_matrix.go
  • pkg/cli/permissions_matrix_test.go
  • pkg/cli/prompt_help.go
  • pkg/cli/prompt_help_content.go
  • pkg/cli/prompt_help_ginkgo_test.go
  • pkg/cli/prompt_render.go
  • pkg/cli/prompt_render_test.go
  • pkg/cli/prompt_run_live.go
  • pkg/cli/prompt_run_workflow_test.go
  • pkg/cli/prompt_schema_build.go
  • pkg/cli/prompt_schema_sandboxes.go
  • pkg/cli/prompt_schema_sandboxes_test.go
  • pkg/cli/prompt_schema_test.go
  • pkg/cli/prompt_spec.go
  • pkg/cli/sandbox.go
  • pkg/cli/sandbox_credentials.go
  • pkg/cli/secret_catalog.go
  • pkg/cli/serve.go
  • pkg/cli/serve_auth.go
  • pkg/cli/serve_auth_test.go
  • pkg/cli/serve_chat.go
  • pkg/cli/serve_credentials.go
  • pkg/cli/serve_git.go
  • pkg/cli/serve_provider_tokens.go
  • pkg/cli/serve_sandbox.go
  • pkg/cli/serve_sandbox_credentials.go
  • pkg/cli/serve_sandbox_credentials_test.go
  • pkg/cli/serve_sandbox_deploy.go
  • pkg/cli/serve_sandbox_deploy_test.go
  • pkg/cli/serve_sandbox_pickers.go
  • pkg/cli/serve_sandbox_test.go
  • pkg/cli/serve_sandbox_update.go
  • pkg/cli/serve_sandbox_whoami.go
  • pkg/cli/testdata/permissions_matrix_test.md
  • pkg/cli/token.go
  • pkg/cli/token_test.go
  • pkg/cli/webapp/src/App.tsx
  • pkg/cli/webapp/src/ChatLayer.tsx
  • pkg/cli/webapp/src/CommandPalette.test.tsx
  • pkg/cli/webapp/src/GitAgentDeployForm.tsx
  • pkg/cli/webapp/src/GitAgentDeployModal.tsx
  • pkg/cli/webapp/src/GitAgentDeployResult.tsx
  • pkg/cli/webapp/src/GitAgentDeployRouting.tsx
  • pkg/cli/webapp/src/GitAgentEnrollModal.tsx
  • pkg/cli/webapp/src/GitAgentTasks.tsx
  • pkg/cli/webapp/src/GitAgentWhoami.tsx
  • pkg/cli/webapp/src/PromptWorkbench.tsx
  • pkg/cli/webapp/src/SandboxCredentials.test.tsx
  • pkg/cli/webapp/src/SandboxCredentials.tsx
  • pkg/cli/webapp/src/SandboxesPage.test.tsx
  • pkg/cli/webapp/src/SandboxesPage.tsx
  • pkg/cli/webapp/src/SandboxesPageEdit.test.tsx
  • pkg/cli/webapp/src/gitAgentDeployValidation.test.ts
  • pkg/cli/webapp/src/gitAgentDeployValidation.ts
  • pkg/cli/webapp/src/gitAgentDeploymentData.ts
  • pkg/cli/webapp/src/sandboxData.ts
  • pkg/cli/webapp/src/shellHelpers.ts
  • pkg/cli/webapp/vite.config.ts
  • pkg/container/base/Dockerfile
  • pkg/container/base/Dockerfile.flanksource
  • pkg/container/base/Dockerfile.lab
  • pkg/container/base/deps.yaml
  • pkg/container/base_image.go
  • pkg/container/base_image_test.go
  • pkg/container/tui.go
  • pkg/credsync/credsync_suite_test.go
  • pkg/credsync/publisher.go
  • pkg/credsync/publisher_test.go
  • pkg/credsync/target_dir.go
  • pkg/credsync/target_k8s.go
  • pkg/database/api_token_store.go
  • pkg/database/api_token_store_integration_test.go
  • pkg/database/caller_tool_legacy_policy_test.go
  • pkg/database/caller_tool_store.go
  • pkg/database/caller_tool_store_integration_test.go
  • pkg/database/git_agent_store.go
  • pkg/database/git_agent_store_integration_test.go
  • pkg/gitagent/admit_ginkgo_test.go
  • pkg/gitagent/deploy/credentials_ginkgo_test.go
  • pkg/gitagent/deploy/deploy_suite_test.go
  • pkg/gitagent/deploy/docker.go
  • pkg/gitagent/deploy/docker_ginkgo_test.go
  • pkg/gitagent/deploy/kubernetes.go
  • pkg/gitagent/deploy/kubernetes_apply_ginkgo_test.go
  • pkg/gitagent/deploy/kubernetes_ingress.go
  • pkg/gitagent/deploy/kubernetes_ingress_ginkgo_test.go
  • pkg/gitagent/deploy/kubernetes_objects.go
  • pkg/gitagent/deploy/kubernetes_objects_ginkgo_test.go
  • pkg/gitagent/deploy/kubernetes_traefik.go
  • pkg/gitagent/deploy/namespace_ginkgo_test.go
  • pkg/gitagent/deploy/plan.go
  • pkg/gitagent/deploy/plan_ginkgo_test.go
  • pkg/gitagent/deploy/security.go
  • pkg/gitagent/deploy/security_ginkgo_test.go
  • pkg/gitagent/dispatch.go
  • pkg/gitagent/dispatchtoken.go
  • pkg/gitagent/dispatchtoken_ginkgo_test.go
  • pkg/gitagent/enroll.go
  • pkg/gitagent/enrollhttps.go
  • pkg/gitagent/httpclient.go
  • pkg/gitagent/httpserver.go
  • pkg/gitagent/httpserver_ginkgo_test.go
  • pkg/gitagent/httpserver_sidecar_ginkgo_test.go
  • pkg/gitagent/probe.go
  • pkg/gitagent/probe_ginkgo_test.go
  • pkg/gitagent/receiver_ginkgo_test.go
  • pkg/gitagent/relay.go
  • pkg/gitagent/scan.go
  • pkg/gitagent/scan_ginkgo_test.go
  • pkg/gitagent/server.go
  • pkg/gitagent/server_ginkgo_test.go
  • pkg/gitagent/tlscert.go
  • pkg/gitagent/tlscert_ginkgo_test.go
  • pkg/gitagent/tokenfile.go
  • pkg/gitagent/tokenfile_ginkgo_test.go
  • pkg/monitor/backfill.go
  • pkg/monitor/gitagent.go
  • pkg/monitor/gitagent_integration_test.go
  • pkg/sandbox/adapter/cli_env.go
  • pkg/sandbox/adapter/gitagent.go
  • pkg/sandbox/adapter/gitagent_dispatch_credentials_test.go
  • pkg/sandbox/adapter/srt.go
  • pkg/sandbox/adapter/srt_test.go
  • pkg/sandbox/adapter/tokens.go
  • pkg/sandbox/runtime_sockets.go
  • pkg/sandbox/token_providers.go
  • pkg/sandbox/token_providers_test.go
  • pkg/sandbox/tokens.go
  • pkg/sandbox/tokens_agentcli.go
  • pkg/sandbox/tokens_agentcli_test.go

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Aug 23, 2026

Copy link
Copy Markdown

Gavel summary

Source Pass Fail Skip Duration

Totals: 0 passed · 0 failed · 0 skipped · -

View full results

@socket-security

socket-security Bot commented Aug 23, 2026

Copy link
Copy Markdown

@socket-security

socket-security Bot commented Aug 23, 2026

Copy link
Copy Markdown

Warning

Review the following alerts detected in dependencies.

According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.

Action Severity Alert  (click "▶" to expand/collapse)
Warn High
Obfuscated code: npm @astrojs/compiler is 90.0% likely obfuscated

Confidence: 0.90

Location: Package overview

From: docs/package.jsonnpm/@astrojs/check@0.9.10npm/@astrojs/compiler@2.13.1

ℹ Read more on: This package | This alert | What is obfuscated code?

Next steps: Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support@socket.dev.

Suggestion: Packages should not obfuscate their code. Consider not using packages with obfuscated code.

Mark the package as acceptable risk. To ignore this alert only in this pull request, reply with the comment @SocketSecurity ignore npm/@astrojs/compiler@2.13.1. You can also ignore all packages with @SocketSecurity ignore-all. To ignore an alert for all future pull requests, use Socket's Dashboard to change the triage state of this alert.

View full report

Comment thread pkg/api/toolpolicy.go Fixed
Comment thread pkg/cli/gitagent_deploy.go Fixed
Comment thread pkg/gitagent/tokenfile.go Fixed
@github-actions

github-actions Bot commented Aug 23, 2026

Copy link
Copy Markdown

Gavel summary

Source Pass Fail Skip Duration
(unknown) 0 1 0 -
./pkg/cli 0 1 0 -
github.com/flanksource/captain/pkg/cli 304 1 0 20.8s
agentcreds 11 0 0 575.618µs
ai 87 0 0 23ms
aichat 135 0 2 12.6s
anthropicmock 1 0 0 2ms
api 223 0 0 42ms
attachments 5 0 0 3ms
bash 4 0 0 195.513µs
callertools 10 0 0 81ms
captain 17 0 0 8.7s
claude 22 0 0 9ms
claudeagent 13 0 0 277ms
cmux 4 0 0 684.782µs
collections 12 0 0 394.758µs
credentials 5 0 0 35ms
credsync 11 0 0 211ms
database 15 0 0 3.0s
deploy 110 0 0 269ms
genkit 25 0 0 53ms
gitagent 122 0 0 14.5s
github.com/flanksource/captain/migrations 11 0 0 4.4s
github.com/flanksource/captain/pkg/ai 250 0 0 550ms
github.com/flanksource/captain/pkg/ai/agent 26 0 0 450ms
github.com/flanksource/captain/pkg/ai/agent/commit 56 0 0 4.1s
github.com/flanksource/captain/pkg/ai/agent/setup 16 0 0 120ms
github.com/flanksource/captain/pkg/ai/agent/verify 21 0 0 390ms
github.com/flanksource/captain/pkg/ai/agent/worktree 6 0 0 -
github.com/flanksource/captain/pkg/ai/assistanttags 15 0 0 -
github.com/flanksource/captain/pkg/ai/fixture 42 0 0 180ms
github.com/flanksource/captain/pkg/ai/fixture/kubeproxy 2 0 0 30ms
github.com/flanksource/captain/pkg/ai/fixture/mcpproxy 6 0 0 -
github.com/flanksource/captain/pkg/ai/history 54 0 0 -
github.com/flanksource/captain/pkg/ai/internal/gen-model-registry 12 0 0 -
github.com/flanksource/captain/pkg/ai/middleware 25 0 0 -
github.com/flanksource/captain/pkg/ai/pricing 9 0 0 20ms
github.com/flanksource/captain/pkg/ai/prompt 16 0 0 10ms
github.com/flanksource/captain/pkg/ai/provider 169 0 1 30ms
github.com/flanksource/captain/pkg/ai/provider/claudeagent 54 0 0 1.6s
github.com/flanksource/captain/pkg/ai/provider/cmux 128 0 0 860ms
github.com/flanksource/captain/pkg/ai/provider/genkit 36 0 0 10ms
github.com/flanksource/captain/pkg/ai/provider/jsonrpc 6 0 0 50ms
github.com/flanksource/captain/pkg/aichat 9 0 0 100ms
github.com/flanksource/captain/pkg/aimock 50 0 7 440ms
github.com/flanksource/captain/pkg/aimock/anthropicmock 14 0 0 10ms
github.com/flanksource/captain/pkg/aimock/openaimock 18 0 0 70ms
github.com/flanksource/captain/pkg/api 143 0 0 400ms
github.com/flanksource/captain/pkg/api/registry 96 0 0 -
github.com/flanksource/captain/pkg/bash 348 0 0 20ms
github.com/flanksource/captain/pkg/captainconfig 25 0 0 -
github.com/flanksource/captain/pkg/captaintoken 23 0 0 1.7s
github.com/flanksource/captain/pkg/claude 138 0 0 20ms
github.com/flanksource/captain/pkg/claude/tools 18 0 0 -
github.com/flanksource/captain/pkg/cmux 1 0 0 -
github.com/flanksource/captain/pkg/codexconfig 10 0 0 10ms
github.com/flanksource/captain/pkg/container 72 0 1 -
github.com/flanksource/captain/pkg/database 130 0 0 19.3s
github.com/flanksource/captain/pkg/dod 11 0 0 1m0s
github.com/flanksource/captain/pkg/gitagent 31 0 0 340ms
github.com/flanksource/captain/pkg/gitagent/proxy 12 0 0 10ms
github.com/flanksource/captain/pkg/monitor 59 0 0 2.5s
github.com/flanksource/captain/pkg/sandbox 13 0 0 -
github.com/flanksource/captain/pkg/sandbox/adapter 39 0 0 -
github.com/flanksource/captain/pkg/sandbox/presets 13 0 0 -
github.com/flanksource/captain/pkg/session 70 0 0 10ms
history 69 0 0 9ms
migrations 8 0 0 4.1s
openaimock 2 0 0 106.998µs
provider 12 0 0 12ms
registry 38 0 0 1ms
session 28 0 0 5ms
tools 53 0 0 3ms

Totals: 3649 passed · 3 failed · 11 skipped · 2m42s

Failing tests

ginkgo Timeout

[1/2] run "direct" iteration 1/1 (model=direct-model)…
    · pid=40119, awaiting first stream-json event…
      → Bash 
      → Bash 
... (92 more lines truncated)```

#### ginkgo Execution

'/home/runner/work/captain/captain/.ginkgo/ginkgo-report-.-pkg-cli-1787499075454719582.json' not found


#### github.com/flanksource/captain/pkg/cli — TestEnrollmentProducesADispatchableTopology

gitagent_e2e_test.go:347: serve exited before listening (exit status 1):
�[2m15:30:18.846�[0m �[91mERR�[0m Command serve failed: a mailbox verifies captain tokens against the database: open captain database context "default" (CAPTAIN_SESSION_DB_URL): acquire Cap...
Error: a mailbox verifies captain tokens against the database: open captain database context "default" (CAPTAIN_SESSION_DB_URL): acquire Captain migration lock: reserve advisory-lock connec...


[View full results](https://github.com/flanksource/captain/actions/runs/32648382829/artifacts/9495625972)

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.

2 participants