Repository navigation
Description
Summary
npm run check on main (currently @ 502b0f4) reports 75 TypeScript errors across 24 files. They're not blocking the build (vite build still succeeds via Svelte's loose-by-default mode), but they hide real type-drift between $lib/types and its consumers, plus a few missing dependencies. Cleaning them up gets the project to a green tsc --noEmit baseline so future drift is caught immediately.
I ran the classification while touching ModelConfigEditor for #213 — happy to send the fixes if useful. Wanted to surface the picture and check scope/priority before opening 5 PRs that might collide with work-in-progress.
Reproduction
git checkout main
npm install
npm run check 2>&1 | grep -c '^[0-9]\+ ERROR'
# → 75Classification
I grouped errors by root cause. Each group is independently fixable; numbers are the count contributed to the 75 total.
| Group | Errors | Files | Root cause |
|---|---|---|---|
A. SubAgent / ParsedSubAgent type drift |
26 | SubAgentForm.svelte (1) |
Component reads disallowedTools, maxTurns, memory, background, effort, isolation, hooks, mcpServers, initialPrompt — none declared on the SubAgent / ParsedSubAgent interfaces. |
| B. Containers feature | 10 | 9 | Missing DockerStatusType export, Container interface drift (isFavorite, dockerHostId etc. used at call sites but absent on type), missing @xterm/xterm and @xterm/addon-fit deps. |
| C. Auto-mode settings fields | 9 | AutoModeEditor.svelte, SettingsAutoModeTab.svelte |
ClaudeSettings missing disableAutoMode, autoModeEnvironment, autoModeAllow, autoModeSoftDeny. |
D. Lucide icon Component<…> mismatch |
7 | ProjectCard, ProjectList, McpLibrary |
lucide-svelte types out of sync with current Svelte runes — RefreshCw, ExternalLink, Trash_2, Package, FolderOpen all flagged. |
E. Keybindings test: "Input" context |
6 | keybindingsLibrary.test.ts |
KeybindingContext union doesn't include "Input" but tests assert it. |
F. ModelOverrides setting field |
3 | ModelOverridesEditor.svelte |
ClaudeSettings.modelOverrides not declared on the interface. |
G. Skill type (SkillType, skillType) |
3 | markdownParser.ts, skillLibrary.test.ts |
SkillType not exported; skillType field used in test fixture but absent on CreateSkillRequest. |
| H. Sessions store rename | 2 | routes/sessions/+page.svelte |
selectedSessionSummary + "sessionSummary" prop no longer exist on SessionStoreState / target component. |
I. ProjectCard toast variant |
1 | ProjectCard.svelte |
"info" not in toast variant union. |
| J. Spinner verbs test fixture | 1 | spinnerverbs.test.ts |
Fixture passes sortOrder, missing from SpinnerVerb. |
K. Tauri InvokeArgs mock |
1 | helpers/invokeMock.ts |
Tauri tightened InvokeArgs; helper still uses Record<string, unknown>. |
| L. Sandbox type missing | 1 | SandboxFilesystemEditor.svelte |
SandboxFiles* not exported from $lib/types. |
M. Subagents selectedProject |
1 | AgentMemoryPanel.svelte |
ProjectsState.selectedProject missing — store restructured. |
Proposed PR sequence
I'd batch these into ~5 PRs to keep review surface small and reverts cheap if any fix turns out to be wrong about intent:
| PR | Groups | Errors fixed | Risk | Notes |
|---|---|---|---|---|
| PR 1 — quick wins | C, F, G, I, J, L | 18 | Low | All additive: add missing fields/exports to $lib/types. No behavior change. |
| PR 2 — SubAgent type drift | A | 26 | Low | Extend SubAgent / ParsedSubAgent to match what the form already reads. Largest payoff per PR. |
| PR 3 — Lucide icon types | D | 7 | Low | Bump lucide-svelte to a version aligned with Svelte runes. Smoke-test icon rendering. |
| PR 4 — test-fixture cleanup | E, H, K, M | 10 | Low | Touches test files + a couple of call sites. Aligns fixtures with current types. |
| PR 5 — containers feature | B | 10 | Med | Touches in-progress containers code. Needs more context on intent. Last in line. |
Total recoverable: 65 / 75 in PRs 1–4 (low risk). PR 5 deferred until you confirm the containers feature direction.
Offer
Happy to open these one at a time against main, smallest first, each with its own test plan. Will hold off until I hear back — if any of these are already in flight on your end, just say which groups to skip. Also fine to close this if npm run check is intentionally not gating; in that case the only thing worth doing is updating package.json script to make that explicit.
(For context: I noticed this while sending #213. None of those 75 errors are caused by that PR.)
Activity
tylergraydev commentedon Apr 30, 2026
Thanks for the careful classification — really helpful framing.
Greenlight to send PRs 1–4 in order, smallest first:
disableAutoMode,autoModeEnvironment,autoModeAllow,autoModeSoftDenyare part of an in-flight Auto Mode settings tab. If those names match what the editor actually reads, just adding them toClaudeSettingsis fine.lucide-svelteto 1.0.1. If the bump alone fixes the runes mismatch, your PR may collapse into a smoke-test confirming icons still render. Otherwise rebase on top of Bump lucide-svelte from 0.577.0 to 1.0.1 #180 once it lands.Hold on PR 5 (containers, group B). Containers + docker hosts are still scaffolded — they don't return real data yet. Errors there reflect type drift on a feature that's in flux, so fixing them now would just re-drift when the feature lands. Defer until that work has direction.
If anything else surfaces while you're in there (
ModelOverridesEditor/AttributionEditorhave their ownstate_referenced_locallywarnings I noticed during PR #213 testing), feel free to flag separately rather than expand scope.Thanks for offering — appreciate it.
fix(types): close 22 svelte-check errors via additive type updates (#214
fix(types): close 3 svelte-check errors — sessions prop + invoke mock (…
fix(types): close 26 svelte-check errors via SubAgent type drift (#214 …
fix(types): close 6 svelte-check errors — keybindings test Input cast (…
deps: bump lucide-svelte to 1.0.1, replace removed Github icon, close #…
deps: bump lucide-svelte to 1.0.1, replace removed Github icon, close #…
tylergraydev commentedon May 16, 2026
Status update — 64/75 errors fixed
Working through the groups from your classification. Net: 75 → 11 errors on
main. Every "type drift / missing field / fixture" group is now resolved. What remains is real work that doesn't belong in this issue's scope.Merged
spinnerverbsfixture typo (sortOrder→displayOrder) — declined to add a phantom field nothing else readsSubAgent/CreateSubAgentRequestand 7 fields toParsedSubAgent. All match the existing Rust struct and round-tripped datasessionSummaryprop from the call site; widenedinvokeMockcallback to Tauri'sInvokeArgs$lib/typesto add anInputcontext. Added one localizedInputcast alias in the test instead of adding a phantom value to the productionKeybindingContextunionlucide-svelte0.577 → 1.0.1. The lucide bump dropped theGithubbrand icon, so I added a smallGithubIcon.svelteto replace it. Also loosenedActionMenuItem/EmptyStateiconprop type — lucide 1.x still exports icons as the legacySvelteComponentTypedshape, which never satisfies Svelte 5's strictComponent<Props>Remaining (11 errors)
These are not type drift — they're either guarded work or latent bugs:
Group B — 10 errors, all in
containers/*. The containers feature is scaffolded but returns empty data (per project memory: "Containers, docker hosts, templates are scaffolded but return empty data"). These errors will resolve naturally when the feature is built out — fixing them now would require either mocking real shapes or papering over the unfinished code. Recommend leaving until the feature ships.Group M — 1 error,
AgentMemoryPanel.svelte:projectsStore.selectedProjectdoesn't exist. This isn't drift —ProjectsStatehas no project-selection concept at all. The panel'sprojectPathderives fromprojectsStore.selectedProject?.path ?? null, which currently always evaluates tonull— the project-scoped agent memory silently never receives a path. This is a real runtime bug, not a missing field; the fix is a data-flow decision (prop pass-through vs route param) that belongs in its own focused PR.Decision
If you want a green
npm run checkgate, the next step is to either decide on the AgentMemoryPanel data flow (closes M) and add acontainersexclusion or progress that feature (closes B). Otherwise I'd consider this issue effectively resolved and close it — the remaining items are tracked by their natural homes (containers feature work, a focused AgentMemoryPanel fix).🤖 Generated with Claude Code
Bump lucide-svelte from 0.577.0 to 1.0.1 (tylergraydev#180)