ci: enable Cursor Max Mode for cursor-agent workflow#121
Merged
Conversation
|
Firetiger deploy monitoring skipped This PR didn't match the auto-monitor filter configured on your GitHub connection:
Reason: PR modifies CI workflow configuration for cursor-agent, but unclear which service in the kernel monorepo is implicated; please clarify the affected service or opt in manually. To monitor this PR anyway, reply with |
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.
Problem
The
update-cli-coverage.ymlworkflow runscursor-agentwith--model ${{ vars.CURSOR_PREFERRED_MODEL }}(currentlyclaude-opus-4-8-xhigh). That model requires Cursor Max Mode, so CI fails withMax Mode Required.A fresh
cursor-agentinstall defaults tomaxMode=false, and it must be explicitly enabled viacli-config.json.Fix
Add an "Enable Cursor Max Mode" step immediately after the Cursor CLI install step and before the agent invocation:
{"maxMode": true}tocli-config.json.CURSOR_CONFIG_DIRand propagates it via$GITHUB_ENV. GitHub-hosted runners setXDG_CONFIG_HOME=/home/runner/.config, and cursor-agent resolves its config dir asCURSOR_CONFIG_DIR || $XDG_CONFIG_HOME/cursor || ~/.cursor. Without pinningCURSOR_CONFIG_DIR, a~/.cursor/cli-config.jsonwrite would be ignored.This mirrors the proven fix already applied in
kernel/kernel.Requirements
The
CURSOR_API_KEYsecret used by the workflow must be Max-Mode-entitled for this to take effect.Note
This repo is auto-generated by Stainless; only the workflow YAML was modified.
Made with Cursor
Note
Low Risk
Workflow-only change; no application or runtime behavior beyond fixing CI agent configuration.
Overview
Fixes
update-cli-coverageCI failures whencursor-agentruns with a model that requires Max Mode (e.g.claude-opus-4-8-xhighviaCURSOR_PREFERRED_MODEL), which errors withMax Mode Requiredon a fresh install.Adds an Enable Cursor Max Mode step right after installing the Cursor CLI: writes
{"maxMode": true}tocli-config.jsonunder$HOME/.cursorand setsCURSOR_CONFIG_DIRin$GITHUB_ENVsocursor-agentpicks up that config instead of ignoring it when runners useXDG_CONFIG_HOME.Reviewed by Cursor Bugbot for commit 9726171. Bugbot is set up for automated code reviews on this repo. Configure here.