{"record":{"id":"a3b6115c9a1b581a","repo":"cube-js/cube","slug":"not-used","errorCode":null,"errorMessage":"not used","messagePattern":"not used","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"rust/cubestore/cubestore/src/store/mod.rs","lineNumber":440,"sourceCode":"#[async_trait]\nimpl ChunkDataStore for ChunkStore {\n    async fn partition_data(\n        &self,\n        table_id: u64,\n        rows: Vec<ArrayRef>,\n        columns: &[Column],\n        in_memory: bool,\n    ) -> Result<Vec<ChunkUploadJob>, CubeError> {\n        let indexes = self\n            .meta_store\n            .get_table_indexes_out_of_queue(table_id)\n            .await?;\n        self.build_index_chunks(table_id, &indexes, rows.into(), columns, in_memory)\n            .await\n    }\n\n    async fn partition(&self, _wal_id: u64) -> Result<(), CubeError> {\n        panic!(\"not used\");\n    }\n\n    async fn repartition(&self, partition_id: u64) -> Result<(), CubeError> {\n        let (partition, index, table, _) = self\n            .meta_store\n            .get_partition_for_compaction(partition_id)\n            .await?;\n        if partition.get_row().is_active() {\n            return Err(CubeError::internal(format!(\n                \"Tried to repartition active partition: {:?}\",\n                partition\n            )));\n        }\n\n        let chunks = self\n            .meta_store\n            .get_chunks_by_partition(partition_id, false)\n            .await?","sourceCodeStart":422,"sourceCodeEnd":458,"githubUrl":"https://github.com/cube-js/cube/blob/7d981676b36392fec34088b9afab6bdcad40207c/rust/cubestore/cubestore/src/store/mod.rs#L422-L458","documentation":"The partition method on this store implementation is explicitly unimplemented: it panics with 'not used' because partition creation for this backend goes through build_index_chunks / repartition paths instead of the trait's partition(_wal_id) entry point. Hitting it means an internal code path called a method that should never be invoked.","triggerScenarios":"Calling partition(_wal_id) directly or an internal flow (e.g. WAL replay invoking partition) that the implementation does not support — any code path expecting this store trait impl to partition raw WAL data.","commonSituations":"Custom code or a modified CubeStore build invoking the PartitionTraits partition method directly; a bug where WAL replay routes work to the unimplemented method.","solutions":["Use the supported ingestion/compaction APIs (build_index_chunks / repartition) rather than partition","Upgrade to an official CubeStore build where WAL handling does not call this method","File a bug with the call stack if reached during normal operation"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":"// avoid custom paths that call partition() directly; prefer supported ingestion\nif (typeof store.partition === 'function' && isOfficialBuild) use supportedIngestionPath(); else useRepartitionPath();","typeGuard":null,"tryCatchPattern":"// in custom Rust integrations, intercept before calling the trait method\nasync fn safe_partition(store: &dyn PartitionTraits, wal_id: u64) -> Result<(), CubeError> {\n    Err(CubeError::internal(\"partition() unsupported for this store; use repartition/build_index_chunks\"))\n}","preventionTips":["Use official CubeStore builds and public APIs only","Route WAL work through replay/repartition paths, not partition()","Review custom patches for calls to unimplemented trait methods","Add integration tests covering ingestion and compaction flows"],"tags":["panic","unimplemented","internal-bug"],"backgroundTag":"unimplemented-code-path","analyzedSha":"7d981676b36392fec34088b9afab6bdcad40207c","analyzedAt":"2026-09-02T03:45:10.400Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T15:18:49.778Z"}