{"record":{"id":"de73e48d75fc91be","repo":"CloakHQ/CloakBrowser","slug":"element-selector-failed-editable-check-element","errorCode":null,"errorMessage":"Element ${selector} failed editable check: element is not editable","messagePattern":"Element (.+?) failed editable check: element is not editable","errorType":"exception","errorClass":"ElementNotEditableError","httpStatus":null,"severity":"error","filePath":"js/src/human/actionability.ts","lineNumber":121,"sourceCode":"// Pre-scroll actionability\n// ---------------------------------------------------------------------------\n\nasync function stealthActionable(\n  pageOrFrame: Page | Frame,\n  selector: string,\n  checks: ReadonlySet<CheckName>,\n): Promise<void> {\n  const world = getWorld(pageOrFrame);\n  if (!world) throw new StealthWorldUnavailableError();\n\n  const { status, data } = await evalParsed(world, buildActionableJs(selector));\n  if (status === UNSUPPORTED) throw new UnsupportedHumanizeSelectorError(selector);\n  if (status === EVALUATION_FAILED) throw new StealthEvaluationError(selector);\n  if (status === NOT_FOUND) throw new ElementNotAttachedError(selector);\n  if (status !== OK || !data) throw new StealthEvaluationError(selector);\n  if (checks.has('visible') && !data.visible) throw new ElementNotVisibleError(selector);\n  if (checks.has('enabled') && !data.enabled) throw new ElementNotEnabledError(selector);\n  if (checks.has('editable') && !data.editable) throw new ElementNotEditableError(selector);\n}\n\nasync function readBox(\n  pageOrFrame: Page | Frame,\n  selector: string,\n): Promise<{ x: number; y: number; width: number; height: number } | null> {\n  const world = getWorld(pageOrFrame);\n  if (!world) throw new StealthWorldUnavailableError();\n\n  const { status, data } = await evalParsed(world, buildBoxJs(selector));\n  if (status === OK && data?.box) return data.box;\n  if (status === NOT_FOUND) return null;\n  if (status === UNSUPPORTED) throw new UnsupportedHumanizeSelectorError(selector);\n  throw new StealthEvaluationError(selector);\n}\n\nexport async function ensureActionable(\n  pageOrFrame: Page | Frame,","sourceCodeStart":103,"sourceCodeEnd":139,"githubUrl":"https://github.com/CloakHQ/CloakBrowser/blob/d6bad5de261bedf025280ace1d14e800aee13923/js/src/human/actionability.ts#L103-L139","documentation":"With 'editable' in checks (used by typing/filling actions), the probe found the element but data.editable === false — the field is read-only or not an editable control.","triggerScenarios":"ensureActionable with 'editable' on readonly inputs (readonly attribute), non-input elements targeted by humanType/humanFill, or inputs made readonly while a request is in flight.","commonSituations":"Typing into readonly/date inputs, masks that toggle readonly during formatting, fields locked during submission, or a wrong selector landing on a div/span instead of the input.","solutions":["Verify the selector resolves to the actual editable input element, not a wrapper","Wait for readonly to clear if the field unlocks after loading: waitForFunction checking !input.readOnly","For non-editable controls (selects, date pickers) use fill/select/keyboard APIs instead of typing","Pass a checks set without 'editable' if the control is legitimately readonly and you use a different interaction"],"exampleFix":"// before\nawait humanType(page, '.date-display', '2024-01-01');\n// after\nawait humanFill(page, 'input[name=\"date\"]', '2024-01-01');","handlingStrategy":"validation","validationCode":"if ((await page.locator(sel).getAttribute('readonly')) !== null) { /* use fill/select instead of typing */ }","typeGuard":"function isElementNotEditableError(e: unknown): e is ElementNotEditableError {\n  return e instanceof Error && /failed editable check/.test(e.message);\n}","tryCatchPattern":"try { await humanType(page, sel, txt); } catch (e) { if (isElementNotEditableError(e)) await page.locator(sel).fill(txt); else throw e; }","preventionTips":["Target the real input element, not wrappers","Wait for readonly masks to unlock before typing","Use fill/select APIs for non-editable controls"],"tags":["readonly","editable","actionability","form"],"backgroundTag":"element-not-editable","analyzedSha":"d6bad5de261bedf025280ace1d14e800aee13923","analyzedAt":"2026-08-28T14:13:12.918Z","schemaVersion":2},"datasetVersion":"2026-08-28T16:17:29.566Z"}