{"record":{"id":"d6f85795a7c96664","repo":"MemPalace/mempalace","slug":"row-idx-id-byte-length-doc-id-bytes-exceeds","errorCode":null,"errorMessage":"row {idx}: id byte length {doc_id_bytes} exceeds {DRAWER_ID_MAX_LENGTH}","messagePattern":"row (.+?): id byte length (.+?) exceeds (.+?)","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"mempalace/backends/milvus.py","lineNumber":510,"sourceCode":"        if metadatas is not None and len(metadatas) != len(ids):\n            raise ValueError(\n                f\"metadatas length {len(metadatas)} does not match ids length {len(ids)}\"\n            )\n        if len(embeddings) != len(ids):\n            raise ValueError(\n                f\"embeddings length {len(embeddings)} does not match ids length {len(ids)}\"\n            )\n        vectors, dimension = _normalize_vectors(embeddings)\n        metadatas = metadatas or [{} for _ in ids]\n        rows = []\n        for idx, (doc_id, document, metadata, vector) in enumerate(\n            zip(ids, documents, metadatas, vectors)\n        ):\n            if not isinstance(doc_id, str) or not doc_id:\n                raise ValueError(f\"row {idx}: id must be a non-empty string\")\n            doc_id_bytes = _utf8_len(doc_id)\n            if doc_id_bytes > DRAWER_ID_MAX_LENGTH:\n                raise ValueError(\n                    f\"row {idx}: id byte length {doc_id_bytes} exceeds {DRAWER_ID_MAX_LENGTH}\"\n                )\n            document = _clean_text(document)\n            document_bytes = _utf8_len(document)\n            if document_bytes > DOCUMENT_MAX_LENGTH:\n                raise ValueError(\n                    f\"row {idx}: document byte length {document_bytes} exceeds \"\n                    f\"Milvus VARCHAR limit {DOCUMENT_MAX_LENGTH}; chunk before storing\"\n                )\n            row = {\n                FIELD_ID: doc_id,\n                FIELD_DOCUMENT: document,\n                FIELD_METADATA: _jsonable_metadata(metadata),\n                FIELD_VECTOR: vector,\n            }\n            row.update(row[FIELD_METADATA])\n            rows.append(row)\n        return rows, dimension","sourceCodeStart":492,"sourceCodeEnd":528,"githubUrl":"https://github.com/MemPalace/mempalace/blob/06cb6987f02610784fefbad4b2bd5d026d164ba6/mempalace/backends/milvus.py#L492-L528","documentation":"Error \"row {idx}: id byte length {doc_id_bytes} exceeds {DRAWER_ID_MAX_LENGTH}\" thrown in MemPalace/mempalace.","triggerScenarios":"Thrown at mempalace/backends/milvus.py:510 when the library encounters an invalid state.","commonSituations":"Drawer id derived from an overly long source path or content exceeded the limit.","solutions":["Shorten drawer ids below the byte limit, or re-chunk so ids stay within DRAWER_ID_MAX_LENGTH"],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"06cb6987f02610784fefbad4b2bd5d026d164ba6","analyzedAt":"2026-08-15T03:03:36.213Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}