Repository navigation
Closed
Labels
Description
Source: GlitchTip sweep of demo.tale.dev, 2026-09-02 (evening pass). Tracked on the board as TAL-29. Born after the morning 06:10Z sweep finished querying, so no prior task or repo issue covers it: #1991 (closed) fixed the human create-task form (client trim/max-length); this is the agent/workspace-tool path.
Evidence
- TALE-PROJECT-12H —
Uncaught ConvexError: {"code":"TASK_TITLE_INVALID"}— 1 event, 2026-09-02T06:10:25Z, error level. Tags:func: tasks/internal_mutations:agentCreateTask(mutation),request_id e799de1b789564f1. Stack:convex/tasks/internal_mutations.ts:199(handler) →:148(trimTitle). - The platform's own nightly triage automation tripped it: the event sits 25 seconds before that run created its task (TAL-28, 06:10:50Z) — the agent passed an empty/whitespace (or over-max) title through the workspace
task_createtool, got an opaque refusal, and recovered by retrying. Every agent that files tasks can reproduce this, and agent traffic on this surface is growing.
Read
"Title is empty after trim / too long" is an expected validation refusal, and it fails badly three ways:
- Code-only error: the ConvexError carries
{code: "TASK_TITLE_INVALID"}with no message, no offending value, no limit — the calling agent cannot tell empty-after-trim from over-max or learnTASK_TITLE_MAX. Contrast the platform's own better convention: connectors'INPUT_INVALIDcarriesmessage+hint+ "you passed: …" (TALE-PROJECT-11M), and the Postgres-port twinservices/platform/backend/domains/tasks/service.ts:210(validateTitle) at least throwsTaskError('TASK_TITLE_INVALID', 'Invalid title'). - Recorded as an uncaught error-level server event — the same expected-refusal-as-uncaught-error class as Bug: request_human_input crashes uncaught when an approval is already pending on the thread — expected conflict surfaced as a plain server Error (5 events, 08-07→08-12) #3111 (approval conflict), Bug: keyless org model resolution throws uncaught NoProviderAvailableError — expected "no AI provider configured yet" onboarding state recorded as error-level server events (8 events, 07-07→07-28, latent) #3129 (keyless org model resolution), and Bug: expected "Unauthenticated" refusals land as uncaught server errors — ~550+ GlitchTip events across 12+ groups, still firing daily #3088's direction 3 (reporting policy).
- Validation sits deep in the internal mutation instead of the agent tool boundary (
workspace_domain_tools/ write shim), so the bridge surfaces a mutation crash rather than a structuredinvalid_argsresult.
Module note: convex/tasks/internal_mutations.ts is private-overlay (absent from the public tree — same situation as #3110/#3111/#3129); the Postgres-port backend/domains/tasks/service.ts and backend/core/node_only/sandbox/workspace_domain_tools.ts are public.
Fix direction
- Message-carrying refusal: throw
ConvexErrorwith code + message + which constraint failed (empty vs >TASK_TITLE_MAX, include the max), aligned with theTaskErrorshape and theINPUT_INVALIDconvention, in both the convex overlay and the Postgres port. - Validate at the tool boundary:
task_create/task_upsert_by_external_refnormalize+validate the title before invoking the mutation, returning a structuredinvalid_argsresult the agent can act on in one round-trip. - Reporting policy: stop recording expected validation refusals as uncaught error-level events (align with Bug: expected "Unauthenticated" refusals land as uncaught server errors — ~550+ GlitchTip events across 12+ groups, still firing daily #3088 direction 3 / Bug: request_human_input crashes uncaught when an approval is already pending on the thread — expected conflict surfaced as a plain server Error (5 events, 08-07→08-12) #3111 / Bug: keyless org model resolution throws uncaught NoProviderAvailableError — expected "no AI provider configured yet" onboarding state recorded as error-level server events (8 events, 07-07→07-28, latent) #3129).
Acceptance
- An agent calling
task_createwith"", whitespace, or an over-max title receives a structured refusal naming the constraint and limit; the run can self-correct without guessing. - No error-level GlitchTip event is minted for it; TALE-PROJECT-12H stays flat.
Filed from the GlitchTip sweep of 2026-09-02. Board task: TAL-29.
Activity
yannickmonney commentedon Sep 27, 2026
#3529 fixes the agent path:
task_createnow refuses a title over 200 characters before any read or write, with aninvalid_argsresult that names the limit and the title's length, and the tool signature states the cap. Still open here: the domain'svalidateTitlethrows the same "Invalid title" for an empty and an over-long title on the human create and update paths. A follow-up task also covers the sibling limits (a description over 20,000 characters and a label over 50 still come back as bare domain codes, becausetoolResultFromErrorkeeps only the code).fix(platform): name every refused limit in task tools and doors