You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[bug] Every Repo Coder subscribed since 2026-08-08 has no working repo_* tool — migration 0102 removed the setting the tools still read, and said no code read it #520
Every Repo Coder subscribed since 2026-08-08 has no working repo_* tool
Migration 0102_coder_repo_drop_repo_setting.sql removed repo from coder-repo's settingsSchema and stated, at line 30:
"With the field off the schema the console stops rendering it, applySettingsPatch (schema-driven) can no longer write it, and no code reads it — it is inert."
The last clause is false.workers/api/src/lib/connectors/repo-local.ts:35:
repoPathForInstance (:69, loop at :79) reads agent_instances.config.settings for those keys and nothing else, and :178 — const workDir = await repoPathForInstance(ctx); — is the only workdir source for all six repo_* tools (repo_tree, repo_read_file, repo_git, repo_remote, and since #508repo_find, repo_grep).
So the setting is unwritable and still required
applySettingsPatch (workers/api/src/lib/instance-settings.ts:71-92) iterates for (const field of schema), so a key absent from the schema cannot be written. resolveSettingsValues (:28) filters reads the same way.
Net effect for a coder-repo instance created after fc01c17 (2026-08-08 04:05 UTC):
the console renders no control for it,
the API cannot accept a value for it,
and six tools require it.
Live proof it is already breaking instances
FIS coder5d14a2e1-140c-466d-beec-ddd331a1e72b, created 2026-08-10 — i.e. after the migration. Its entire conversation history is one failed call:
❌ repo_remote — "No repository is configured for this agent."
By contrast both Chess instances predate the migration and kept their stored values: Chess coder 2bd43f4de… works, and Chess coderbfc76603… holds the wrong path that 0102's own header quotes as the original bug report — and it cannot be corrected from the UI, which is why that instance is dead.
get_instance_settings(bd43f4de) returns only engine / autonomy / merge_policy; the repo path is invisible even where it exists and works.
#513's fix assumed the opposite, and reintroduced the class
#513 (closed, c6eaf74) fixed a message that named the wrong control. Its body asserts:
"A coder-repo instance has a different field, labelled "Repository" (migration 0063)"
True before 0102, false since. Post-fix, repo-local.ts:142 finds no matching schema field, hint.label falls back to "the repository setting", and repoMissingMessage (:172) still ends with "in the console (Settings → Agent settings)" — a card that has no such control. So the agent still directs the owner to a control that does not exist, which is the same defect class as #513 and #517, reintroduced by #513's own premise.
What a fix has to decide
0102's intent was right — the bug it fixed was real (a setting and a coding_repos row disagreeing, with the one-way wire firing only on CREATE). The error is that it removed the input while leaving the reader. Three possible shapes:
Point repo_* at coding_repos.workdir — the row the Coding tab already manages, which is where the truth now lives. Most consistent with 0102's reasoning; needs a decision about which repo when an instance has several (surfaceOptions.coding.repos:"single" bounds it for coder-repo).
Restore the schema field and re-establish the wire both ways. Undoes 0102 and re-opens the divergence it closed.
Keep the field off the schema but give repoPathForInstance a writable path — smallest change, but leaves two sources of truth, which is exactly what 0102 was fixing.
(1) looks correct, but this is a decision about where a Repo Coder's repo lives, so it should be made deliberately rather than by whichever edit is smallest.
Acceptance criteria
A coder-repo instance created today can be given a repository through the console, and its repo_* tools work.
FIS coder 5d14a2e1 specifically becomes usable — it is the live casualty and the acceptance test.
Instances created before 0102 keep working with no manual migration (Chess coder 2 must not regress).
A test binds the reader to the writer, so a future schema edit cannot orphan a required setting again. This is the second time a "no code reads it" claim in a migration comment turned out to be wrong; the guard is what stops a third.
0102's comment is corrected — its claim is load-bearing and untrue. Note check-migrations --require-history permits a comment-only edit precisely for this case.
Verified vs inferred
Verified:REPO_PATH_SETTINGS at repo-local.ts:35, the schema-driven write at instance-settings.ts:71-92, 0102's text, FIS coder's failing history, both Chess instances' states, and get_instance_settings output.
Inferred: that every post-0102coder-repo instance is affected. One is confirmed (FIS coder); the mechanism implies the rest, and no counter-example was found.
Every Repo Coder subscribed since 2026-08-08 has no working
repo_*toolMigration
0102_coder_repo_drop_repo_setting.sqlremovedrepofromcoder-repo'ssettingsSchemaand stated, at line 30:The last clause is false.
workers/api/src/lib/connectors/repo-local.ts:35:repoPathForInstance(:69, loop at:79) readsagent_instances.config.settingsfor those keys and nothing else, and:178—const workDir = await repoPathForInstance(ctx);— is the only workdir source for all sixrepo_*tools (repo_tree,repo_read_file,repo_git,repo_remote, and since #508repo_find,repo_grep).So the setting is unwritable and still required
applySettingsPatch(workers/api/src/lib/instance-settings.ts:71-92) iteratesfor (const field of schema), so a key absent from the schema cannot be written.resolveSettingsValues(:28) filters reads the same way.Net effect for a
coder-repoinstance created afterfc01c17(2026-08-08 04:05 UTC):Live proof it is already breaking instances
FIS coder
5d14a2e1-140c-466d-beec-ddd331a1e72b, created 2026-08-10 — i.e. after the migration. Its entire conversation history is one failed call:By contrast both Chess instances predate the migration and kept their stored values: Chess coder 2
bd43f4de…works, and Chess coderbfc76603…holds the wrong path that0102's own header quotes as the original bug report — and it cannot be corrected from the UI, which is why that instance is dead.get_instance_settings(bd43f4de)returns onlyengine/autonomy/merge_policy; the repo path is invisible even where it exists and works.#513's fix assumed the opposite, and reintroduced the class
#513 (closed,
c6eaf74) fixed a message that named the wrong control. Its body asserts:True before
0102, false since. Post-fix,repo-local.ts:142finds no matching schema field,hint.labelfalls back to"the repository setting", andrepoMissingMessage(:172) still ends with "in the console (Settings → Agent settings)" — a card that has no such control. So the agent still directs the owner to a control that does not exist, which is the same defect class as #513 and #517, reintroduced by #513's own premise.What a fix has to decide
0102's intent was right — the bug it fixed was real (a setting and acoding_reposrow disagreeing, with the one-way wire firing only on CREATE). The error is that it removed the input while leaving the reader. Three possible shapes:repo_*atcoding_repos.workdir— the row the Coding tab already manages, which is where the truth now lives. Most consistent with0102's reasoning; needs a decision about which repo when an instance has several (surfaceOptions.coding.repos:"single"bounds it forcoder-repo).0102and re-opens the divergence it closed.repoPathForInstancea writable path — smallest change, but leaves two sources of truth, which is exactly what0102was fixing.(1) looks correct, but this is a decision about where a Repo Coder's repo lives, so it should be made deliberately rather than by whichever edit is smallest.
Acceptance criteria
coder-repoinstance created today can be given a repository through the console, and itsrepo_*tools work.5d14a2e1specifically becomes usable — it is the live casualty and the acceptance test.0102keep working with no manual migration (Chess coder 2 must not regress).repoMissingMessagenames a control that exists, or says plainly that none does — the [bug] An unconfigured Repo Coder tells the owner to set "Repository path" — a field that agent does not have — and declines GitHub work that needs no repo at all #513/[bug] A refused tool's own remedy is discarded and the agent invents "Settings → Connections" — reproduced 5/5, and the transcript truncates the real remedy away #517 rule.0102's comment is corrected — its claim is load-bearing and untrue. Notecheck-migrations --require-historypermits a comment-only edit precisely for this case.Verified vs inferred
REPO_PATH_SETTINGSatrepo-local.ts:35, the schema-driven write atinstance-settings.ts:71-92,0102's text, FIS coder's failing history, both Chess instances' states, andget_instance_settingsoutput.0102coder-repoinstance is affected. One is confirmed (FIS coder); the mechanism implies the rest, and no counter-example was found.