{"record":{"id":"5b2a26dfe6a0b1d7","repo":"NousResearch/hermes-agent","slug":"notepad-full-job-job-id-would-exceed-max-job","errorCode":null,"errorMessage":"notepad full: job '{job_id}' would exceed {MAX_JOB_TOTAL_BYTES} bytes total; delete unused keys first","messagePattern":"notepad full: job '(.+?)' would exceed (.+?) bytes total; delete unused keys first","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"cron/notepad.py","lineNumber":109,"sourceCode":"        )\n\n\ndef set_note(job_id: str, key: str, value: str) -> Dict[str, Any]:\n    \"\"\"Upsert one key. Raises ValueError when a size cap would be exceeded.\"\"\"\n    job_id, key, value = str(job_id), str(key), str(value)\n    _validate(job_id, key, value)\n    now = _hermes_now().isoformat()\n    with _transaction() as conn:\n        row = conn.execute(\n            \"\"\"SELECT COALESCE(SUM(LENGTH(CAST(key AS BLOB))\n                 + LENGTH(CAST(value AS BLOB))), 0)\n               FROM cron_notepad WHERE job_id=? AND key<>?\"\"\",\n            (job_id, key),\n        ).fetchone()\n        other_bytes = int(row[0])\n        entry_bytes = len(key.encode(\"utf-8\")) + len(value.encode(\"utf-8\"))\n        if other_bytes + entry_bytes > MAX_JOB_TOTAL_BYTES:\n            raise ValueError(\n                f\"notepad full: job '{job_id}' would exceed \"\n                f\"{MAX_JOB_TOTAL_BYTES} bytes total; delete unused keys first\"\n            )\n        conn.execute(\n            \"\"\"INSERT INTO cron_notepad (job_id, key, value, updated_at)\n               VALUES (?, ?, ?, ?)\n               ON CONFLICT(job_id, key)\n               DO UPDATE SET value=excluded.value, updated_at=excluded.updated_at\"\"\",\n            (job_id, key, value, now),\n        )\n    return {\"job_id\": job_id, \"key\": key, \"value\": value, \"updated_at\": now}\n\n\ndef get_note(job_id: str, key: str) -> Optional[str]:\n    with _transaction() as conn:\n        row = conn.execute(\n            \"SELECT value FROM cron_notepad WHERE job_id=? AND key=?\",\n            (str(job_id), str(key)),","sourceCodeStart":91,"sourceCodeEnd":127,"githubUrl":"https://github.com/NousResearch/hermes-agent/blob/c896c09c42910c584c4c7d2325b58c14713ea42c/cron/notepad.py#L91-L127","documentation":"Error \"notepad full: job '{job_id}' would exceed {MAX_JOB_TOTAL_BYTES} bytes total; delete unused keys first\" thrown in NousResearch/hermes-agent.","triggerScenarios":"Thrown at cron/notepad.py:109 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Delete unused notepad keys for this job, then retry.","Split data across fewer/smaller entries to stay under the total cap."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"c896c09c42910c584c4c7d2325b58c14713ea42c","analyzedAt":"2026-08-14T17:18:01.089Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}