From 05eb203918e31353ec754b9c7b67c094ccd6c6e0 Mon Sep 17 00:00:00 2001 From: Naoya Matayoshi Date: Tue, 17 Mar 2026 11:21:26 +0900 Subject: [PATCH] Fix orb init failing when orb-publishing context already exists The error string check in initOrb used a hardcoded message that no longer matches what the REST API (or GQL API) returns when a context with the same name already exists. Use a case-insensitive check for "already exists" so the CLI gracefully continues regardless of which API path is used. Fixes #1192 Made-with: Cursor --- cmd/orb.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/orb.go b/cmd/orb.go index d81511b01..97285622c 100644 --- a/cmd/orb.go +++ b/cmd/orb.go @@ -1405,7 +1405,7 @@ func initOrb(opts orbOptions) error { contextAPI := context.NewContextClient(opts.cfg, "", vcsProvider, ownerName) err = contextAPI.CreateContext("orb-publishing") if err != nil { - if strings.Contains(err.Error(), "A context named orb-publishing already exists") { + if strings.Contains(strings.ToLower(err.Error()), "already exists") { fmt.Println("`orb-publishing` context already exists, continuing on") } else { return err