feat(config): flatten results.export.* to results.*#1258
Merged
Conversation
….yaml
The `results` block currently only contains `export` as a single sibling,
so `results.export.{repo,path,auto_push,branch_prefix}` carries no information
that flat `results.{repo,path,auto_push,branch_prefix}` wouldn't. The `export`
name was also misleading — the same config governs sync/read (the cached
clone), not just push.
Rename:
- `ResultsExportConfig` → `ResultsConfig`
- `normalizeResultsExportConfig` → `normalizeResultsConfig`
Inline `parseResultsExportConfig` into `parseResultsConfig`. Flatten the
validator and all test fixtures, docs, and Studio user-facing copy.
Breaking change: configs using `results.export.{repo,path,...}` must move
to `results.{repo,path,...}`. The config is undocumented elsewhere and
zero committed examples used it.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The
results.export.*schema in.agentv/config.yamlis redundant nesting —resultshas exactly one sibling (export), soresults.export.{repo,path,auto_push,branch_prefix}carries no information that flatresults.{repo,path,auto_push,branch_prefix}wouldn't. Theexportname is also misleading: the same block governs sync/read of the cached clone, not just push.This PR flattens the schema.
Before:
After:
Why now
apps/web/src/content/docs/docs/tools/studio.mdx) and not used by any committed.agentv/config.yaml(template, example, or root). The introducing PR (feat(results): export remote runs and sync Studio #994) had no example file either. Flattening is free now, painful later.results.exportas a single feature, not a namespace. No sibling underresultswas planned or implemented.execution.*is flat (execution.trace_file,execution.otel_file) — flatresults.*matches that convention.Changes
Renames (internal):
ResultsExportConfig→ResultsConfignormalizeResultsExportConfig→normalizeResultsConfigparseResultsExportConfigis inlined intoparseResultsConfig.Schema:
parseResultsConfig(packages/core/src/evaluation/loaders/config-loader.ts) readsrepo/path/auto_push/branch_prefixdirectly offresults.validateConfig(packages/core/src/evaluation/validation/config-validator.ts) drops the nestedexportlayer; error locations are nowresults.repo,results.path, etc.Consumers:
apps/cli/src/commands/results/remote.ts—config.results.export→config.results.apps/studio/src/components/RunSourceToolbar.tsx,apps/studio/src/routes/index.tsx) updated to mentionresultsinstead ofresults.export.Tests: YAML fixtures flattened in
config-loader.test.ts,config-validator.test.ts, andapps/cli/test/commands/results/serve.test.ts(2 places).Docs:
apps/web/src/content/docs/docs/tools/studio.mdxexample updated.Breaking change
Existing
.agentv/config.yamlfiles usingresults.export.{repo,path,...}will silently stop being detected (validator will warn thatresults.repois missing). No backward-compat shim is shipped — the schema is undocumented and (per my knowledge) not yet in use.Verification
bun --filter @agentv/core test→ 1774 pass, 0 failbun --filter agentv test→ 548 pass, 0 failbun --filter @agentv/core typecheck→ cleanbun --filter agentv typecheck→ cleanbunx tsc -p apps/studio/tsconfig.json --noEmit→ cleanbun run lint→ cleanTest plan
.agentv/config.yamlusingresults.export.*results.repo/results.pathlocally, runagentv eval, verify auto-push orStudio /api/remote/statusstill works🤖 Generated with Claude Code