Skip to content

chore(agent): make sandbox-agent runner first-class#4786

Open
mmabrouk wants to merge 1 commit into
mainfrom
chore/sandbox-agent-core
Open

chore(agent): make sandbox-agent runner first-class#4786
mmabrouk wants to merge 1 commit into
mainfrom
chore/sandbox-agent-core

Conversation

@mmabrouk

@mmabrouk mmabrouk commented Jun 20, 2026

Copy link
Copy Markdown
Member

Context

The agent runtime POC still refers to the runner sidecar through older names and scattered self-host docs. Review needs a deployment-oriented core slice that documents the sandbox-agent service and wires the local/dev compose surfaces without taking Railway, Kubernetes, or image-build CI.

This PR is intentionally part of the existing agent-workflows POC stack. Review it with #4771, #4772, #4776, #4778, and #4779; it is not meant to merge alone.

Changes

Moves the sidecar deployment proposal into a project folder with status tracking, adds self-host docs for the agent runner and Daytona sandboxes, and updates OSS/EE local compose/env examples to expose the sandbox-agent service shape. It also adds runner docs and test scaffolding for the first-class sandbox-agent name.

Child PRs:

Tests / notes

  • Previously verified as part of the working tree with pnpm run typecheck and pnpm test in services/agent, relevant Python unit tests, compose config checks, and Helm template renders.
  • Does not include Railway, Kubernetes, published image builds, or CI changes. Those are split into child PRs.
  • There are still unrelated unassigned changes in the GitButler workspace from other POC work; they were not included here.

What to QA

  • In the local OSS and EE compose examples, confirm the API service can point at sandbox-agent through the documented env variables.
  • Read the self-host runner docs and confirm Railway, Kubernetes, and custom image references point to the follow-up PRs rather than this core slice.

@dosubot dosubot Bot added the size:XL This PR changes 500-999 lines, ignoring generated files. label Jun 20, 2026
@vercel

vercel Bot commented Jun 20, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
agenta-documentation Error Error Jun 20, 2026 11:40pm

Request Review

@coderabbitai

coderabbitai Bot commented Jun 20, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

Release Notes

  • Documentation

    • Added comprehensive agent runner deployment guides for self-hosted setups, covering Docker Compose, Helm, and Railway deployments.
    • Added configuration documentation for agent runner environment variables and their mappings.
    • Added guide for configuring Daytona as the sandbox provider for agent workflows.
    • Added agent runner architecture documentation.
    • Created deployment proposal and status documentation.
  • Infrastructure

    • Updated Docker Compose configurations to include the sandbox-agent service by default across all deployment variants.

Walkthrough

Introduces sandbox-agent as a first-class deployable runner service across Docker Compose (OSS dev/local/SSL, EE local), with env example updates replacing old Daytona blocks. Adds self-host documentation guides and a design proposal with status tracking. Implements three new TypeScript source modules (skills.ts, entry.ts, version.ts) and ships a full Vitest unit test suite for all agent runner subsystems.

Changes

sandbox-agent Runner Rollout

Layer / File(s) Summary
Deployment proposal and status docs
docs/design/agent-workflows/sidecar-deployment-proposal/README.md, docs/design/agent-workflows/sidecar-deployment-proposal/proposal.md, docs/design/agent-workflows/sidecar-deployment-proposal/status.md
Adds planning README, a full deployment/env-contract/image/docs proposal (519 lines), and an implementation status document recording decisions, open questions, and next steps.
Self-host configuration, guides, and architecture docs
docs/docs/self-host/02-configuration.mdx, docs/docs/self-host/guides/07-deploy-the-agent-runner.mdx, docs/docs/self-host/guides/09-agent-daytona-sandboxes.mdx, docs/docs/self-host/infrastructure/01-architecture.mdx
Adds Agent runner env var table to the configuration reference, two new deployment guides (agent runner and Daytona sandboxes), and extends the architecture page with a sandbox-agent Runner subsection and backend dependencies.
Docker Compose sandbox-agent service wiring
hosting/docker-compose/oss/docker-compose.dev.yml, hosting/docker-compose/oss/docker-compose.gh.local.yml, hosting/docker-compose/oss/docker-compose.gh.ssl.yml, hosting/docker-compose/ee/docker-compose.gh.local.yml, hosting/docker-compose/oss/env.oss.dev.example, hosting/docker-compose/ee/env.ee.dev.example
Adds a sandbox-agent service definition with healthcheck and AGENTA_AGENT_RUNNER_URL/MCP env wiring to all Compose variants; replaces old DAYTONA_* env blocks with SANDBOX_AGENT_* blocks in dev example files.
Agent runner source modules
services/agent/src/engines/skills.ts, services/agent/src/entry.ts, services/agent/src/version.ts, services/agent/AGENTS.md, services/agent/CLAUDE.md
Adds resolveSkillDirs for bundled skill directory resolution, isEntrypoint() for entry-point detection, and runnerInfo() with versioning constants. Updates AGENTS.md with package conventions and wire-contract update procedures; converts CLAUDE.md to a symlink.
Vitest config, golden fixture utility, and wire contract tests
services/agent/vitest.config.ts, services/agent/tests/utils/golden.ts, services/agent/tests/unit/wire-contract.test.ts
Adds Vitest configuration (node env, JUnit reporter, v8 coverage), a cross-language golden fixture loader, and wire contract tests with compile-time drift guards (KNOWN_REQUEST_KEYS, CAPABILITY_KEYS) validating request and result shapes against JSON golden fixtures.
HTTP server and CLI transport unit tests
services/agent/tests/unit/server.test.ts, services/agent/tests/unit/cli.test.ts
Tests /health response shape, POST /run success/invalid-JSON/failure/NDJSON-streaming paths against a real ephemeral server, and runCli exit codes, JSON output shapes, and streaming record ordering.
Stream events and responder unit tests
services/agent/tests/unit/stream-events.test.ts, services/agent/tests/unit/responder.test.ts
Tests createSandboxAgentOtel delta/lifecycle state machine in streaming, one-shot, and span-less modes; tests policyFromRequest, decisionToReply, PolicyResponder, and emitEvent routing to live sink and batch log.
Tool bridge, dispatch, code execution, extension, and MCP unit tests
services/agent/tests/unit/tool-bridge.test.ts, services/agent/tests/unit/tool-dispatch.test.ts, services/agent/tests/unit/code-tool.test.ts, services/agent/tests/unit/extension-tools.test.ts, services/agent/tests/unit/mcp-servers.test.ts
Tests buildToolMcpServers attachment decisions and env isolation, buildCustomTools/runResolvedTool/relayToolCall routing and file relay, Python/Node subprocess execution with env isolation, Pi extension tool registration, and toAcpMcpServers conversion.
Continuation, skills, and protocol utility unit tests
services/agent/tests/unit/continuation.test.ts, services/agent/tests/unit/skills.test.ts
Tests messageTranscript encoding, resolveRunSessionId fallback, buildTurnText replay, and resolveSkillDirs path resolution, skipping, logger invocation, and no-op handling.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 30.00% which is insufficient. The required threshold is 60.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title 'chore(agent): make sandbox-agent runner first-class' accurately summarizes the main objective of establishing sandbox-agent as a first-class deployment component across the codebase.
Description check ✅ Passed The description comprehensively explains the context, changes, testing approach, and QA validation points related to making sandbox-agent first-class, directly addressing the changeset's scope.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/sandbox-agent-core

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 and usage tips.

@github-actions

Copy link
Copy Markdown
Contributor

Railway Preview Environment

Preview URL https://gateway-production-8410.up.railway.app/w
Project agenta-oss-pr-4786
Image tag pr-4786-ebb35f4
Status Deployed
Railway logs Open logs
Workflow logs View workflow run
Updated at 2026-06-20T23:46:21.237Z

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

🧹 Nitpick comments (2)
docs/design/agent-workflows/sidecar-deployment-proposal/proposal.md (1)

154-168: ⚡ Quick win

Missing SANDBOX_AGENT_DAYTONA_INSTALL_PI from the runner service configuration contract.

Section 4b lists the runner service env contract, but SANDBOX_AGENT_DAYTONA_INSTALL_PI is absent. However, this variable is present in the actual Docker Compose wiring (hosting/docker-compose/oss/docker-compose.gh.local.yml) and documented in the configuration reference (02-configuration.mdx, line 136). It should be added to the table in section 4b for completeness.

The variable controls whether the Pi harness is installed in Daytona sandboxes and is a legitimate part of the runner's configuration contract.

📝 Proposed fix for section 4b
| `SANDBOX_AGENT_DAYTONA_SNAPSHOT` | unset | Snapshot name for Daytona runs. |
| `SANDBOX_AGENT_DAYTONA_IMAGE` | unset | Plain image override for Daytona runs when no snapshot is set. |
+| `SANDBOX_AGENT_DAYTONA_INSTALL_PI` | `false` | Install Pi harness in Daytona sandbox images (only for custom snapshots). |
docs/docs/self-host/guides/07-deploy-the-agent-runner.mdx (1)

22-28: ⚡ Quick win

Clarify or document the image override environment variables.

Lines 25–26 reference AGENTA_SANDBOX_AGENT_IMAGE_NAME and AGENTA_SANDBOX_AGENT_IMAGE_TAG as optional Compose overrides, but these variables are not documented in the configuration reference (02-configuration.mdx) or the proposal's configuration contract (sections 4a–4b). The Docker Compose template uses ${AGENTA_VERSION} rather than these named variables.

Either:

  • Add them to the configuration reference if they are part of the official self-host contract, or
  • Remove them if they are undocumented internal details not meant for operators, or
  • Clarify with a note (e.g., "advanced: for custom registries") if they are Compose-level overrides for specialized deployments.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: b837c7a0-d3de-4e7a-8e17-9c22461ee14f

📥 Commits

Reviewing files that changed from the base of the PR and between a97e608 and 05437f9.

📒 Files selected for processing (32)
  • docs/design/agent-workflows/sidecar-deployment-proposal/README.md
  • docs/design/agent-workflows/sidecar-deployment-proposal/proposal.md
  • docs/design/agent-workflows/sidecar-deployment-proposal/status.md
  • docs/docs/self-host/02-configuration.mdx
  • docs/docs/self-host/guides/07-deploy-the-agent-runner.mdx
  • docs/docs/self-host/guides/09-agent-daytona-sandboxes.mdx
  • docs/docs/self-host/infrastructure/01-architecture.mdx
  • hosting/docker-compose/ee/docker-compose.gh.local.yml
  • hosting/docker-compose/ee/env.ee.dev.example
  • hosting/docker-compose/oss/docker-compose.dev.yml
  • hosting/docker-compose/oss/docker-compose.gh.local.yml
  • hosting/docker-compose/oss/docker-compose.gh.ssl.yml
  • hosting/docker-compose/oss/env.oss.dev.example
  • services/agent/AGENTS.md
  • services/agent/CLAUDE.md
  • services/agent/src/engines/skills.ts
  • services/agent/src/entry.ts
  • services/agent/src/version.ts
  • services/agent/tests/unit/cli.test.ts
  • services/agent/tests/unit/code-tool.test.ts
  • services/agent/tests/unit/continuation.test.ts
  • services/agent/tests/unit/extension-tools.test.ts
  • services/agent/tests/unit/mcp-servers.test.ts
  • services/agent/tests/unit/responder.test.ts
  • services/agent/tests/unit/server.test.ts
  • services/agent/tests/unit/skills.test.ts
  • services/agent/tests/unit/stream-events.test.ts
  • services/agent/tests/unit/tool-bridge.test.ts
  • services/agent/tests/unit/tool-dispatch.test.ts
  • services/agent/tests/unit/wire-contract.test.ts
  • services/agent/tests/utils/golden.ts
  • services/agent/vitest.config.ts

Comment on lines +30 to +45
## Optional snapshot

Daytona runs start faster from a prepared snapshot. Agenta ships the recipe, not a
prebuilt snapshot:

```bash
cd services/agent/sandbox-images/daytona
uv run build_snapshot.py --force
```

Then configure the snapshot name:

```bash
SANDBOX_AGENT_DAYTONA_SNAPSHOT=agenta-sandbox-pi
SANDBOX_AGENT_DAYTONA_INSTALL_PI=false
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check for the snapshot build directory and script
if [[ -f services/agent/sandbox-images/daytona/build_snapshot.py ]]; then
  echo "build_snapshot.py found."
  head -20 services/agent/sandbox-images/daytona/build_snapshot.py
else
  echo "build_snapshot.py not found; check for build documentation."
  fd -type f -name "*snapshot*" -o -name "*daytona*" services/agent/
fi

# Check for README or docs
fd -type f -name "README*" services/agent/sandbox-images/daytona/ 2>/dev/null

Repository: Agenta-AI/agenta

Length of output: 309


🏁 Script executed:

#!/bin/bash
# Check the actual structure of services/agent/
ls -la services/agent/sandbox-images/ 2>/dev/null || echo "Directory not found"

# Search for any snapshot-related files
fd -type f -name "*snapshot*" services/ 2>/dev/null | head -20

# Search for build scripts
fd -type f -name "build*.py" services/ 2>/dev/null | head -20

# Check if daytona directory exists
ls -la services/agent/sandbox-images/daytona 2>/dev/null || echo "daytona directory not found"

Repository: Agenta-AI/agenta

Length of output: 108


🏁 Script executed:

#!/bin/bash
# Search for uv references in docs
rg -i "uv" docs/ --type markdown -A 2 -B 2 | head -50

# Search for uv in entire codebase  
rg -i "^uv " --type markdown --type python | head -30

Repository: Agenta-AI/agenta

Length of output: 5784


🏁 Script executed:

#!/bin/bash
# Check the actual documentation file mentioned
cat -n docs/docs/self-host/guides/09-agent-daytona-sandboxes.mdx | head -60

Repository: Agenta-AI/agenta

Length of output: 1759


Remove or replace the non-existent snapshot build instructions—the referenced directory and script do not exist in the repository.

Lines 36–37 reference services/agent/sandbox-images/daytona/build_snapshot.py, but:

  • The directory services/agent/sandbox-images/ does not exist in the codebase
  • The script build_snapshot.py does not exist

Users following this guide will encounter an immediate "No such file or directory" error. Either:

  1. Restore the snapshot build tooling and document its setup (including uv installation and Python prerequisites), or
  2. Remove the "Optional snapshot" section entirely if snapshot building is not supported in self-hosted deployments, or
  3. Link to separate, complete snapshot build documentation if it exists elsewhere

- ${ENV_FILE:-./.env.oss.dev}
environment:
DOCKER_NETWORK_MODE: ${DOCKER_NETWORK_MODE:-bridge}
AGENTA_AGENT_RUNNER_URL: http://sandbox-agent:8765

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Allow overriding AGENTA_AGENT_RUNNER_URL in dev compose.

Line 410 hardcodes the runner URL, so values from the selected env file cannot override it. This diverges from the other compose variants and breaks the expected env-driven runner routing.

Suggested fix
-            AGENTA_AGENT_RUNNER_URL: http://sandbox-agent:8765
+            AGENTA_AGENT_RUNNER_URL: ${AGENTA_AGENT_RUNNER_URL:-http://sandbox-agent:8765}
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
AGENTA_AGENT_RUNNER_URL: http://sandbox-agent:8765
AGENTA_AGENT_RUNNER_URL: ${AGENTA_AGENT_RUNNER_URL:-http://sandbox-agent:8765}

Comment on lines +23 to +30
import {
type AgentRunRequest,
type AgentRunResult,
type HarnessCapabilities,
messageText,
resolvePromptText,
resolveRunSessionId,
} from "../../src/protocol.ts";

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify that protocol.ts exports the required types and functions
PROTOCOL_FILE="services/agent/src/protocol.ts"

echo "=== Checking exports in src/protocol.ts ==="
if [ ! -f "$PROTOCOL_FILE" ]; then
  echo "✗ Protocol file not found: $PROTOCOL_FILE"
  exit 1
fi

echo "Checking for required exports:"
for export in "AgentRunRequest" "AgentRunResult" "HarnessCapabilities" "messageText" "resolvePromptText" "resolveRunSessionId"; do
  if grep -q "export.*$export" "$PROTOCOL_FILE"; then
    echo "$export"
  else
    echo "$export not found"
  fi
done

Repository: Agenta-AI/agenta

Length of output: 162


🏁 Script executed:

# Find protocol.ts and wire-contract.test.ts files
fd -type f -name "protocol.ts"
fd -type f -name "wire-contract.test.ts"

Repository: Agenta-AI/agenta

Length of output: 402


🏁 Script executed:

# Find protocol.ts and wire-contract.test.ts files
fd -t f "protocol.ts"
fd -t f "wire-contract.test.ts"

Repository: Agenta-AI/agenta

Length of output: 108


🏁 Script executed:

# Search for any files with "protocol" in the name
fd -t f "protocol"

# List the services/agent directory structure
ls -la services/agent/
ls -la services/agent/src/ 2>/dev/null || echo "src directory not found"

Repository: Agenta-AI/agenta

Length of output: 762


🏁 Script executed:

# List all .ts files in services/agent recursively
find services/agent -name "*.ts" -o -name "*.tsx" | head -20

# Read the wire-contract.test.ts file to see what it's importing
cat services/agent/tests/unit/wire-contract.test.ts | head -40

Repository: Agenta-AI/agenta

Length of output: 2312


🏁 Script executed:

# Search for any file named protocol.ts anywhere
find . -name "protocol.ts" 2>/dev/null

# Search for where these symbols are defined
rg "export.*AgentRunRequest" --type ts

rg "export.*messageText" --type ts

rg "export.*resolvePromptText" --type ts

Repository: Agenta-AI/agenta

Length of output: 42


🏁 Script executed:

# Check the full wire-contract.test.ts content
wc -l services/agent/tests/unit/wire-contract.test.ts

# Read the entire test file
cat services/agent/tests/unit/wire-contract.test.ts

# Search without type filter
grep -r "AgentRunRequest" . 2>/dev/null | head -10

Repository: Agenta-AI/agenta

Length of output: 7910


🏁 Script executed:

# Check continuation.test.ts to see how it imports AgentRunRequest
grep -A 5 -B 5 "AgentRunRequest" services/agent/tests/unit/continuation.test.ts | head -20

# Check if there's a protocol file anywhere with a different name or location
fd -t f "protocol" services/agent/

Repository: Agenta-AI/agenta

Length of output: 618


🏁 Script executed:

# Check if protocol.ts is gitignored or in git history
cd services/agent && git status src/protocol.ts 2>&1 || echo "Not in git status"

# Check git log for protocol.ts
cd services/agent && git log --oneline src/protocol.ts 2>&1 | head -5

# Look at what's in sandbox_agent.ts to see if it has any of these exports
grep -E "export.*(AgentRunRequest|messageText|resolvePromptText|resolveRunSessionId)" services/agent/src/engines/sandbox_agent.ts

Repository: Agenta-AI/agenta

Length of output: 286


🏁 Script executed:

# Use git ls-files to find all relevant files
git ls-files | grep -E "protocol\.ts|wire-contract\.test\.ts|sandbox_agent\.ts"

# Check current working directory
pwd

# List services directory
ls -la services/ 2>/dev/null | head -20

Repository: Agenta-AI/agenta

Length of output: 928


🏁 Script executed:

# Check if protocol.ts exists in the filesystem at all
test -f services/agent/src/protocol.ts && echo "EXISTS" || echo "NOT FOUND"

# Check for any file named protocol in services/agent
find services/agent -name "*protocol*" 2>/dev/null

# Check if there's a .gitignore entry
cat services/agent/.gitignore 2>/dev/null || echo "No .gitignore in services/agent"

# List all files in services/agent/src/
ls -la services/agent/src/ 2>/dev/null

Repository: Agenta-AI/agenta

Length of output: 388


🏁 Script executed:

# Search for where AgentRunRequest might be defined anywhere
rg "AgentRunRequest\s*=" --type ts

# Search for type AgentRunRequest anywhere
rg "type\s+AgentRunRequest" --type ts

# Look for interface AgentRunRequest
rg "interface\s+AgentRunRequest" --type ts

# Check all imports in continuation.test.ts 
cat services/agent/tests/unit/continuation.test.ts | head -30

Repository: Agenta-AI/agenta

Length of output: 1633


Create services/agent/src/protocol.ts with the required type and function exports.

The test file imports AgentRunRequest, AgentRunResult, HarnessCapabilities, messageText, resolvePromptText, and resolveRunSessionId from ../../src/protocol.ts, but this file does not exist. The test will fail to compile. You need to create services/agent/src/protocol.ts and export all six of these items (three types and three functions) with signatures that match the test's usage patterns.

Comment on lines +13 to +18
const here = dirname(fileURLToPath(import.meta.url));
// services/agent/tests/utils -> repo root -> the shared Python golden fixtures.
export const GOLDEN_DIR = join(
here,
"../../../../sdks/python/oss/tests/pytest/unit/agents/golden",
);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Verify golden fixture directory and files exist
REPO_ROOT=$(git rev-parse --show-toplevel)
GOLDEN_DIR="${REPO_ROOT}/sdks/python/oss/tests/pytest/unit/agents/golden"

echo "=== Checking golden fixture directory ==="
if [ -d "$GOLDEN_DIR" ]; then
  echo "✓ Directory exists: $GOLDEN_DIR"
  echo ""
  echo "=== Fixture files present ==="
  ls -la "$GOLDEN_DIR"/*.json 2>/dev/null || echo "No JSON files found"
else
  echo "✗ Directory not found: $GOLDEN_DIR"
  exit 1
fi

Repository: Agenta-AI/agenta

Length of output: 192


🏁 Script executed:

#!/bin/bash
# Search for the mentioned golden fixture JSON files
echo "=== Searching for golden fixture JSON files ==="
fd -t f \( -name "run_request.pi.json" -o -name "run_request.claude.json" -o -name "run_result.ok.json" -o -name "run_result.error.json" \)
echo ""
echo "=== Searching for any 'golden' directories ==="
fd -t d -i golden
echo ""
echo "=== Searching for GOLDEN_DIR usage in codebase ==="
rg "GOLDEN_DIR" --type ts --type tsx

Repository: Agenta-AI/agenta

Length of output: 485


🏁 Script executed:

#!/bin/bash
# Find and examine wire-contract.test.ts
echo "=== Searching for wire-contract.test.ts ==="
fd -t f -name "wire-contract.test.ts"

Repository: Agenta-AI/agenta

Length of output: 353


🏁 Script executed:

#!/bin/bash
# Search for golden fixture JSON files with corrected syntax
echo "=== Searching for golden fixture JSON files ==="
find . -type f \( -name "run_request.pi.json" -o -name "run_request.claude.json" -o -name "run_result.ok.json" -o -name "run_result.error.json" \) 2>/dev/null
echo ""
echo "=== Searching for any 'golden' directories ==="
find . -type d -iname "*golden*" 2>/dev/null
echo ""
echo "=== Searching for GOLDEN_DIR usage ==="
rg "GOLDEN_DIR" 2>/dev/null || echo "No matches found"

Repository: Agenta-AI/agenta

Length of output: 370


🏁 Script executed:

#!/bin/bash
# Find wire-contract.test.ts and golden.ts file
echo "=== Locating golden.ts ==="
find . -name "golden.ts" 2>/dev/null
echo ""
echo "=== Locating wire-contract.test.ts ==="
find . -name "wire-contract.test.ts" 2>/dev/null
echo ""
echo "=== Examining services/agent/tests directory structure ==="
ls -la services/agent/tests/utils/ 2>/dev/null || echo "Directory not found"

Repository: Agenta-AI/agenta

Length of output: 443


🏁 Script executed:

#!/bin/bash
# Examine the golden.ts file to see how GOLDEN_DIR is used
echo "=== Content of golden.ts ==="
cat -n services/agent/tests/utils/golden.ts
echo ""
echo "=== Check wire-contract.test.ts for fixture usage ==="
cat -n services/agent/tests/unit/wire-contract.test.ts

Repository: Agenta-AI/agenta

Length of output: 8986


🏁 Script executed:

#!/bin/bash
# Search for imports of golden functions in test files
echo "=== Search for golden fixture usage in tests ==="
rg "import.*golden|from.*golden" services/agent/tests/ 2>/dev/null || echo "No imports found"
echo ""
echo "=== Search for the specific JSON file references ==="
rg "run_request|run_result" services/agent/tests/ 2>/dev/null || echo "No references found"

Repository: Agenta-AI/agenta

Length of output: 861


Golden fixture directory and files are missing — tests will fail at runtime.

The directory sdks/python/oss/tests/pytest/unit/agents/golden/ does not exist in the repository, and none of the fixture files referenced by wire-contract.test.ts are present:

  • run_request.pi.json
  • run_request.claude.json
  • run_result.ok.json
  • run_result.error.json

The loadGolden() function in golden.ts and all calls to it in wire-contract.test.ts will fail when the tests are executed. Either commit the missing fixture files to the repository or ensure they are generated before tests run.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

devops documentation Improvements or additions to documentation size:XL This PR changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant