{"record":{"id":"95a95b029905bcd5","repo":"dbt-labs/dbt-core","slug":"count-occurrences-of-value-in-row","errorCode":null,"errorMessage":"count_occurrences_of_value_in_row","messagePattern":"count_occurrences_of_value_in_row","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/dbt-agate/src/table.rs","lineNumber":318,"sourceCode":"            tuple\n        })\n    }\n\n    pub fn count_occurrences_of_row(&self, _needle: &Value) -> usize {\n        todo!(\"count_occurrences_of_row\")\n    }\n\n    pub fn index_of_row(&self, _needle: &Value) -> Option<usize> {\n        todo!(\"index_of_row\")\n    }\n\n    pub fn count_occurrences_of_value_in_row(\n        self: &Arc<Self>,\n        _needle: &Value,\n        row_idx: isize,\n    ) -> usize {\n        let _row = self.row_by_index(row_idx).unwrap();\n        todo!(\"count_occurrences_of_value_in_row\")\n    }\n\n    pub fn index_of_value_in_row(\n        self: &Arc<Self>,\n        _needle: &Value,\n        row_idx: isize,\n    ) -> Option<usize> {\n        let _row = self.row_by_index(row_idx).unwrap();\n        todo!(\"index_of_value_in_row\")\n    }\n\n    pub(crate) fn limit(&self, n: i64) -> Result<TableRepr, ArrowError> {\n        if n < 0 {\n            return Err(ArrowError::ComputeError(\n                \"Table.limit: count must be non-negative\".to_string(),\n            ));\n        }\n        let take = (n as u64).min(self.num_rows() as u64);","sourceCodeStart":300,"sourceCodeEnd":336,"githubUrl":"https://github.com/dbt-labs/dbt-core/blob/0267ce9170576975b76b64ce856b2e5848e96617/crates/dbt-agate/src/table.rs#L300-L336","documentation":"Unimplemented agate Table method: count_occurrences_of_value_in_row should count how often a needle Value appears within one row (located by row index, already fetched via row_by_index), but the body is a todo!() stub.","triggerScenarios":"Thrown at crates/dbt-agate/src/table.rs:318 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Iterate the fetched row's cells counting agate-equal matches","Guard the row index with a bounds error before counting","Return an unsupported error instead of panicking until implemented"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"0267ce9170576975b76b64ce856b2e5848e96617","analyzedAt":"2026-09-07T21:53:39.732Z","contentChangedAt":"2026-09-07T21:53:39.732Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}