Skip to content

feat(workspace): per-repo materialization in static workspace mode#962

Merged
christso merged 2 commits intomainfrom
feat/961-static-per-repo-materialize
Apr 7, 2026
Merged

feat(workspace): per-repo materialization in static workspace mode#962
christso merged 2 commits intomainfrom
feat/961-static-per-repo-materialize

Conversation

@christso
Copy link
Copy Markdown
Collaborator

@christso christso commented Apr 7, 2026

Summary

  • Static workspaces with YAML-configured workspace.path now check each repo's target directory individually
  • Existing repos are reused as-is (no clone, no fetch); only missing repos are cloned
  • CLI-provided --workspace-path behavior unchanged (skips all repo operations)

This enables migrating eval configs from type: local to type: git sources (required for agentv workspace deps discovery) without losing local folder reuse on dev machines.

Changes

packages/core/src/evaluation/orchestrator.ts

  • Hoisted isYamlConfiguredPath to outer scope (was block-scoped inside the static workspace block)
  • Added needsPerRepoCheck flag: triggers when static workspace is populated + YAML-configured + has repos
  • Per-repo loop: existsSync(targetDir) → reuse; missing → repoManager.materialize()

packages/core/test/evaluation/orchestrator.test.ts

  • materializes only missing repos in YAML-configured static workspace — pre-creates repo-a, leaves repo-b missing; verifies repo-a reused and repo-b clone attempted
  • skips all repos when all exist in YAML-configured static workspace — pre-creates both repos; verifies no network/clone operations (succeeds with fake git URLs)

Test plan

  • All 1852 existing tests pass (0 regressions)
  • New test: partial repos present → only missing repos materialized
  • New test: all repos present → no clone attempts (succeeds with fake URLs)
  • Existing test: CLI --workspace with repos → still skips all materialization
  • Build, typecheck, lint all pass

Closes #961

🤖 Generated with Claude Code

Static workspaces with YAML-configured paths now check each repo's
target directory individually. Existing repos are reused as-is; only
missing repos are cloned. This enables migrating from type: local to
type: git sources for deps scanner discovery without losing local
folder reuse.

CLI-provided --workspace-path continues to skip all repo operations
(user-managed directory).

Closes #961

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Apr 7, 2026

Deploying agentv with  Cloudflare Pages  Cloudflare Pages

Latest commit: db5e44e
Status: ✅  Deploy successful!
Preview URL: https://051d2a1e.agentv.pages.dev
Branch Preview URL: https://feat-961-static-per-repo-mat.agentv.pages.dev

View logs

The static workspace section described populated directories as "reused
as-is" with clone "bypassed entirely". Updated to reflect per-repo
behavior: existing repos reused, missing repos cloned. Also clarified
the CLI --workspace-path vs YAML workspace.path distinction.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@christso christso marked this pull request as ready for review April 7, 2026 11:29
@christso christso merged commit 8ac6756 into main Apr 7, 2026
4 checks passed
@christso christso deleted the feat/961-static-per-repo-materialize branch April 7, 2026 11:29
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.

feat(workspace): per-repo materialization in static workspace mode

1 participant