Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.
Go
feat(runtime): allow qoder as a custom runtime profile base (#4883) (#4912)
Bohan Jiang129efb768841
diff --git a/packages/core/types/agent.ts b/packages/core/types/agent.tsindex 4d0b5f2eab..5893754174 100644--- a/packages/core/types/agent.ts+++ b/packages/core/types/agent.ts@@ -109,6 +109,7 @@ export const RUNTIME_PROFILE_PROTOCOL_FAMILIES = ["kimi","kiro","antigravity",+ "qoder",] as const;export type RuntimeProtocolFamily =diff --git a/server/migrations/134_runtime_profile_add_qoder.down.sql b/server/migrations/134_runtime_profile_add_qoder.down.sqlnew file mode 100644index 0000000000..8b78d01c2d--- /dev/null+++ b/server/migrations/134_runtime_profile_add_qoder.down.sql@@ -0,0 +1,19 @@+ALTER TABLE runtime_profile DROP CONSTRAINT IF EXISTS runtime_profile_protocol_family_check;++-- Restore the pre-134 whitelist (migration 126 shape, without qoder). NOT VALID+-- keeps the historical Gemini tolerance so the rollback cannot fail on old rows.+ALTER TABLE runtime_profile ADD CONSTRAINT runtime_profile_protocol_family_check+ CHECK (protocol_family IN (+ 'claude',+ 'codebuddy',+ 'codex',+ 'copilot',+ 'opencode',+ 'openclaw',+ 'hermes',+ 'pi',+ 'cursor',+ 'kimi',+ 'kiro',+ 'antigravity'+ )) NOT VALID;diff --git a/server/migrations/134_runtime_profile_add_qoder.up.sql b/server/migrations/134_runtime_profile_add_qoder.up.sqlnew file mode 100644index 0000000000..22d0ed9a3c--- /dev/null+++ b/server/migrations/134_runtime_profile_add_qoder.up.sql@@ -0,0 +1,23 @@+ALTER TABLE runtime_profile DROP CONSTRAINT IF EXISTS runtime_profile_protocol_family_check;++-- Widen the whitelist to include Qoder so Qoder CN (`qoderclicn`) users can base+-- a custom runtime profile on the existing Qoder backend (launches+-- `<command> --yolo --acp`) instead of misrouting through Kiro/ACP with+-- incompatible arguments (#4883). NOT VALID mirrors migration 126 so a+-- historical Gemini row it intentionally tolerated does not block the upgrade.+ALTER TABLE runtime_profile ADD CONSTRAINT runtime_profile_protocol_family_check+ CHECK (protocol_family IN (+ 'claude',+ 'codebuddy',+ 'codex',+ 'copilot',+ 'opencode',+ 'openclaw',+ 'hermes',+ 'pi',+ 'cursor',+ 'kimi',+ 'kiro',+ 'antigravity',+ 'qoder'+ )) NOT VALID;diff --git a/server/pkg/agent/agent.go b/server/pkg/agent/agent.goindex 223b43a7c6..86d5584dfe 100644--- a/server/pkg/agent/agent.go+++ b/server/pkg/agent/agent.go@@ -137,10 +137,11 @@ type Config struct {//// SupportedTypes is the canonical whitelist of agent types eligible to back a// custom runtime profile. It MUST stay in lockstep with the-// runtime_profile.protocol_family CHECK constraint (migration 120): a custom-// runtime profile may only be based on a backend Multica officially supports.-// (qoder is a built-in provider New can construct, but it is not offered as a-// custom-profile base, so it is intentionally absent from this list.)+// runtime_profile.protocol_family CHECK constraint (migration 120, widened by+// migration 134 to add qoder): a custom runtime profile may only be based on a+// backend Multica officially supports. qoder is exposed here so Qoder CN+// (`qoderclicn`) users can point the Qoder backend at a non-default binary+// instead of misrouting through Kiro/ACP with incompatible arguments (#4883).var SupportedTypes = []string{"claude","codebuddy",@@ -154,6 +155,7 @@ var SupportedTypes = []string{"kimi","kiro","antigravity",+ "qoder",}// IsSupportedType reports whether agentType is in the SupportedTypes whitelist.diff --git a/server/pkg/agent/agent_supported_types_test.go b/server/pkg/agent/agent_supported_types_test.goindex b455f99dae..4b1d54f602 100644--- a/server/pkg/agent/agent_supported_types_test.go+++ b/server/pkg/agent/agent_supported_types_test.go@@ -40,6 +40,7 @@ func TestSupportedTypesMatchesMigrationWhitelist(t *testing.T) {"claude": true, "codebuddy": true, "codex": true, "copilot": true,"opencode": true, "openclaw": true, "hermes": true,"pi": true, "cursor": true, "kimi": true, "kiro": true, "antigravity": true,+ "qoder": true,}if len(SupportedTypes) != len(want) {t.Fatalf("SupportedTypes has %d entries, migration whitelist has %d; keep them in lockstep", len(SupportedTypes), len(want))