Repository navigation
fix(cursor): include project and user settings by default - #859
Merged
Merged
Conversation
stamp-build Bot
added a commit
that referenced
this pull request
Nov 17, 2026
<!-- stamp:review:v1 --> <sup><img src="https://cdn.slock.ai/avatars/6aabf32c-20bc-4cba-b55a-2aa72b60999b/8ba4452ceb890f1930886ef4286fdb99.webp" width="16" height="16" align="absmiddle" alt=""> <b>Otter</b> from open-agent-runtime opened this pull request through Stamp</sup><br><sup><a href="https://stamp.build/review?receipt=prc_2d5b8af87ad8116bbf8fbe220dbe8862"><picture><source media="(prefers-color-scheme: dark)" srcset="https://stamp.build/assets/brand/stamp-glyph-dark.d907ffcadb44.svg"><img src="https://stamp.build/assets/brand/stamp-glyph-light.58a2c10ed108.svg" width="13" height="12" align="absmiddle" alt=""></picture> View in Stamp →</a></sup> --- <!-- /stamp:review:v1 --> Cursor sessions now load user and project settings, but `skills()` still reports unsupported. Add metadata discovery for the SDK 1.4.0 loading roots, including Git-workspace nested skills, with `view: "discovered"`, native filtering and deduplication, and measured user/project scope. Malformed or unreadable metadata and unavailable nested scanning report `partial`; skill bodies and parser errors stay out of the result. The SDK exposes no importable standalone loader. The reader follows the measured rules and uses its ripgrep companion for ignore semantics. A vendor test loads the same fixtures with the real SDK and compares every valid entry. Its test-only SDK copy adds an observation hook without changing loading logic; the product never patches or starts the SDK. The comparison runs on Linux, macOS and Windows in CI and fails when the pinned version or observation anchor changes. Validation: `CI=1 pnpm run check` passed (4,528 tests and 18 mock behavior cases); the product build passed; both offline Linux SDK comparisons passed (17 and 21 valid entries) with preserved symlinks. No account or model request was used. Non-UTF-8 files are deliberately omitted with `partial`, since the SDK also supports encodings this reader does not decode. Windows CI exposed a bootstrap failure before skill loading: the copied SDK could not resolve a dependency. Canonicalizing its path alone did not fix it. The test observer now resolves external imports from the installed SDK entry using a process-local Node hook, preserving package import conditions, subpaths and transitive dependencies while keeping relative observer modules in the copy. Two synthetic dependency layouts pass; the old directory-junction strategy fails the nested layout. The original Windows layout was not retained, so this proves the removed assumption, not the precise Windows cause. Current-head Windows verification remains required. A separate Pi Windows cleanup assertion also failed on the preceding head; its exit/process diagnostics are retained and the new CI run provides the next observation. Source inventory, limitations, reproduction and selected evidence: `experiments/cursor-skills/README.md` and `evidence.json`. Follows #859. --------- Co-authored-by: Otter <[email protected]>
Merged
stamp-build Bot
added a commit
that referenced
this pull request
Nov 17, 2026
<!-- stamp:review:v1 --> <sup><img src="https://api.raft.build/api/avatars/pixel/bXVn.svg" width="16" height="16" align="absmiddle" alt=""> <b>Cindy</b> from open-agent-runtime opened this pull request through Stamp</sup><br><sup><a href="https://stamp.build/review?receipt=prc_684733a8fac75d3d8da33449df10dbc3"><picture><source media="(prefers-color-scheme: dark)" srcset="https://stamp.build/assets/brand/stamp-glyph-dark.d907ffcadb44.svg"><img src="https://stamp.build/assets/brand/stamp-glyph-light.58a2c10ed108.svg" width="13" height="12" align="absmiddle" alt=""></picture> View in Stamp →</a></sup> --- <!-- /stamp:review:v1 --> Two additions to result unions that exhaustive hosts must handle (Kimi usage `unavailable`, inventory `not_authenticated`), behavior changes for Kimi usage and default Cursor sessions, a pre-session capability declaration, skill lists for Antigravity, Cursor, Devin, DSH and Factory, and DSH goals. ## Union additions: handle these if you switch exhaustively - **`AccountUsageSnapshot` gains `{ kind: "unavailable", reason: "access_token_expired" }`** (new exported type `AccountUsageUnavailableReason`) (#865). This read has no current access token and did not try to refresh it. No sign-in is requested, and it can clear once the runtime refreshes the token itself; it does not assert that the refresh token is valid. It differs from `reauth_required` (the user must sign in) and `unsupported` (this runtime or installation cannot read usage). Today only Kimi returns it, when Kimi's native credential lock is unavailable (any platform other than Linux and macOS, or `KIMI_DISABLE_OAUTH_LOCK=1`) and the stored access token has expired but has a refresh token. - **Inventory `unavailable` gains `code: "not_authenticated"`** (#870): the native query needs the runtime to be signed in; signing in restores it. Today only Antigravity `skills()` returns it. ## Kimi usage (#865), behavior change - On Linux and macOS, every `accountUsage()` read now goes through Kimi's own Web service (it starts `kimi web` for each read; cold startup measured about 2 s on Linux). Kimi refreshes an expired token and writes its credential under its own cross-process lock; OAR never writes or rotates Kimi credentials. Starting `kimi web` writes Kimi's device, server-token, log and index files and can use the network. - Without the native lock, an expired token with a refresh token returns the new `unavailable` result without sending a request, so OAR never rotates the user's refresh token behind their own `kimi`. - An expired token with no refresh token is now `reauth_required` / `credentials_missing` without a request (it used to reach the endpoint and come back as `credentials_rejected`). A credential Kimi marked revoked is `reauth_required` / `credentials_rejected`. - The CLI prints the new result. ## Default Cursor sessions load user and project settings (#859), behavior change Cursor SDK 1.4.0 treats an omitted `settingSources` as "none", so OAR's default and `userConfiguration: "include"` sessions were silently ignoring installed configuration. They now pass `["project", "user"]`: user and project skills, configured hooks and MCP servers, and project rules load. Team, MDM and plugin sources are not selected, and model selection is unchanged (model values in `cli-config.json` are not read). `userConfiguration: "exclude"` still passes `[]`; use it to keep the previous behavior. ## Session capabilities before open (#866) `runtime.sessionCapabilities?.(installation)` returns `{ steer?, images? }` synchronously, with no process or I/O, so a host can lay out a composer or filter runtimes before any session exists. A value equals what the opened session will have (`session.steer` present, `capabilities.images`). A field is absent where only the native handshake at open can tell: steering on OpenCode 2 or an unreadable OpenCode version and on DSH, and image input on Antigravity, CodeBuddy, Devin, Kimi and OpenCode. Treat absent as unknown, not false. Every built-in runtime declares, and so does `scriptedRuntime` (`{ steer: true, images: true }`). New exported type `SessionCapabilityDeclaration`. ## Skills (#861, #862, #864, #870, #873) - **Antigravity**: native `agy --output-format json --print=/skills`, with no model request and no saved conversation. It checks sign-in first (`agy models`) and returns `not_authenticated` instead of starting a login, and turns off agy's auto-update for this query only (`AGY_CLI_DISABLE_AUTO_UPDATE=true`). A `GEMINI_HOME` override is refused with `scope_unavailable`. - **Cursor**: metadata discovery following the SDK 1.4.0 loading roots; CI compares the result with the real SDK loader on Linux, macOS and Windows. It reports what a default session sees and never imports or starts the SDK, hooks or MCP servers. In in-process mode it refuses an `env` overlay. New runtime dependency `gray-matter` 4.0.3 (pinned), the parser family the SDK uses. - **Devin**: native `devin skills list --json`, including built-ins. - **DSH**: the native `skills.snapshot({cwd})` through the existing bridge, keeping the native completeness flag and source categories. - **Factory**: native `droid.list_skills` before any session is created, keeping disabled (`enabled: false`) and hidden skills. - **Costs:** these readers start the native runtime and can use the network and write native state: Antigravity creates built-in skill files, logs and an empty history database and can reformat settings without changing values; Devin attempts feature-flag and telemetry connections; Factory creates caches and logs; DSH may activate user plugins. `orient()` runs them only when asked to include customization. - **`partial`, behavior change:** for native catalogs `partial` now follows the runtime's own report (Devin row errors, DSH `complete`, Factory `projectAvailable: false`). Pi RPC `skills()` and `commands()` were always `partial: true` and are now `false` on a successful query. Cursor's local scan marks unreadable, malformed or non-UTF-8 metadata and an unavailable nested scan as partial. - CodeBuddy stays `unsupported`; the reasons are recorded (#872). ## DSH goals (#858) `goals: true` enables DSH's native goal controls: set, read and clear through the installed goal service, with `goal_changed` records. A token budget and `set({ status: "blocked" })` are refused (DSH budgets count rounds, and blocking needs a reason the options cannot carry). Snapshots carry no token budget or token counters. Pausing cancels the running goal turn; clearing leaves it running. ## Also - Antigravity 1.5.9 on Linux: a command agy has moved to the background survives an accepted abort, the turn can end before that command finishes, and `dispose()` ends it; the spec's abort table is updated (#868). - Design: extending sessions OAR did not start is out of scope, with the conditions for reopening (#860). - Kimi login test: checks that the browser helper exits from outside Kimi's process (#874). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Cindy <[email protected]>
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.
Cursor SDK 1.4.0 treats omitted
local.settingSourcesas an empty selection. OAR previously omitted it for default/include sessions, silently ignoring installed user and project configuration. Create and resume now explicitly pass["project", "user"]; exclusion continues to pass[].Release note: default Cursor sessions now load user/project skills, execute configured hooks and connect configured MCP servers, as well as loading project rules. Hosts wanting the previous exclusion must set
userConfiguration: "exclude". Model selection and the explicit sandbox setting retain their existing behavior. This PR does not add skill listing.Validation: default/include failed four mapping regressions before the fix; create/resume controls now pass.
CI=1 pnpm run checkpassed (4522 tests, 18 mock behavior cases). Six controls using the unmodified SDK, isolated sibling home/project fixtures and a synthetic local backend verify actual hook execution, MCP connections, project rule reads, unchanged explicit model selection and stored-login reuse. No real account, model inference or external connection was used. The backend deliberately returns an inference error; this is not a successful-model-turn claim. Reproduction, selected observations and retained-raw fingerprints are in the report.Scope and default-configuration policy confirmed by Cindy in Raft task #core:#245; the broader skills work originated in xxchan's runtime discovery request.