Skip to content

Commit 1d846ac

Browse files
sjarmakclaude
andcommitted
fix: auto-detect artifact configs for MCP-unique selection files
When --selection-file points to a file containing mcp_suite tasks, automatically switch to mcp-remote-artifact config instead of requiring manual --full-config override. Explicit --full-config still takes precedence. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 28c4134 commit 1d846ac

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

configs/run_selected_tasks.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ RUN_BASELINE=true
5959
RUN_FULL=true
6060
CATEGORY="${CATEGORY:-staging}"
6161
FULL_CONFIG="${FULL_CONFIG:-mcp-remote-direct}"
62+
_FULL_CONFIG_EXPLICIT=false
6263
DRY_RUN=false
6364
SKIP_COMPLETED=false
6465
SKIP_PREBUILD=false
@@ -104,6 +105,7 @@ while [[ $# -gt 0 ]]; do
104105
;;
105106
--full-config)
106107
FULL_CONFIG="$2"
108+
_FULL_CONFIG_EXPLICIT=true
107109
shift 2
108110
;;
109111
--skip-completed)
@@ -134,6 +136,20 @@ if [ ! -f "$SELECTION_FILE" ]; then
134136
exit 1
135137
fi
136138

139+
# Auto-detect artifact config for MCP-unique selection files
140+
# MCP-unique tasks use mcp_suite (not benchmark) and REQUIRE artifact configs.
141+
if [ "$_FULL_CONFIG_EXPLICIT" = false ]; then
142+
if python3 -c "
143+
import json, sys
144+
data = json.load(open('$SELECTION_FILE'))
145+
has_mcp_suite = any('mcp_suite' in t for t in data.get('tasks', []))
146+
sys.exit(0 if has_mcp_suite else 1)
147+
" 2>/dev/null; then
148+
FULL_CONFIG="mcp-remote-artifact"
149+
echo "Auto-detected MCP-unique selection file → using artifact configs ($FULL_CONFIG)"
150+
fi
151+
fi
152+
137153
load_credentials
138154

139155
enforce_subscription_mode

0 commit comments

Comments
 (0)