provider: moved Cursor users get plugin 0.2.3: where a proxy or network blocks HTTP/2 ("h2 is not supported"), a Cursor chat goes over HTTP/1.1 as RunSSE + BidiAppend on api2 instead of failing (magpie-community/plugins#59, kazecreator)

Behind TLS inspection or a network that drops HTTP/2, every moved Cursor
chat failed with 502 "Cursor: h2 is not supported" or never answered, while
sign-in, models and usage worked. 0.2.3 falls back to Cursor's own HTTP/1.1
transport; a failure that says HTTP/2 itself can't be had keeps later Runs
on HTTP/1.1 for 10 minutes. The cursor mover's min goes from 0.2.2 to
0.2.3, so keepMovedCurrent updates every moved Cursor user.

0.2.3 on npm (registry.npmjs.org) has an index.mjs byte-identical to
plugins main 5b67ff4. The plugin PR was reviewed at f5c11b7 and merged:
- bun test in packages/cursor: 66 pass, 0 fail, three runs
- whole repo: 1026 pass, 0 fail; bun scripts/check.mjs all 15 pass
- each guarded piece broken by hand turns http1.test.mjs red
- not tried with a real Cursor account on the review side

go test -tags nogui ./internal/provider passes (temp HOME, pinned caches).
go vet -tags nogui ./internal/provider passes for darwin, linux and windows.
gofmt -l is clean.
This commit is contained in:
yetone committed 2026-10-10 09:38:24 +08:00
1 parent 83c963c466
commit 0d5fdbb2de
1 file changed
+1 -1
+1 -1
View File
@@ -221,7 +221,7 @@ func init() {
// the plugin reads cursor-agent's token as the built-in does.
movers["cursor"] = &mover{
pkg: "@magpie-community/opencode-cursor-auth",
min: "0.2.2", // a failure's status and its sign-in mark as the built-in's; Max Mode models retried in Max Mode; glm-5.3 listed; catalog entries written as CallDynamicTool calls, an empty turn retried (plugins #11); a tool step's usage from the dashboard's usage event, cache included (#676); far from Cursor a step whose event shows late is counted by the conversation's next steps instead of guessed (#1053); a turn's parallel calls split over two assistant messages keep their results (#1275); the list is Cursor's picker, a model once per context size with that window, effort and fast sent as the variant's parameters, and an id 0.1.x listed still runs as the variant it stood for (plugins #51); an id 0.1.x listed, at an effort only its other branch has, goes as that branch's nearest effort, not as the default's id with parameters that contradict it (plugins #54); a model listed at a size Cursor has a fast variant of says fast, for magpie's Fast switch (#1360)
min: "0.2.3", // a failure's status and its sign-in mark as the built-in's; Max Mode models retried in Max Mode; glm-5.3 listed; catalog entries written as CallDynamicTool calls, an empty turn retried (plugins #11); a tool step's usage from the dashboard's usage event, cache included (#676); far from Cursor a step whose event shows late is counted by the conversation's next steps instead of guessed (#1053); a turn's parallel calls split over two assistant messages keep their results (#1275); the list is Cursor's picker, a model once per context size with that window, effort and fast sent as the variant's parameters, and an id 0.1.x listed still runs as the variant it stood for (plugins #51); an id 0.1.x listed, at an effort only its other branch has, goes as that branch's nearest effort, not as the default's id with parameters that contradict it (plugins #54); a model listed at a size Cursor has a fast variant of says fast, for magpie's Fast switch (#1360); a Run HTTP/2 can't open (a proxy or network that blocks it, "h2 is not supported") goes over HTTP/1.1 as RunSSE + BidiAppend on api2 (plugins #59)
agents: []string{"cursor"},
out: func() ([]Moving, error) {
if CursorExecutable() == "" || cursorSignedOut() {