{"record":{"id":"f0e1db06a302d19a","repo":"FyroxEngine/Fyrox","slug":"node-row-out-of-bounds-row-column","errorCode":null,"errorMessage":"Node row out of bounds: {} row:{}, column:{}","messagePattern":"Node row out of bounds: (.+?) row:(.+?), column:(.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"fyrox-ui/src/grid.rs","lineNumber":457,"sourceCode":"        }\n    }\n    fn calc_needed_measurements(&self, ui: &UserInterface) {\n        let mut rows = self.rows.borrow_mut();\n        let mut cols = self.columns.borrow_mut();\n        for dim in rows.iter_mut().chain(cols.iter_mut()) {\n            dim.unmeasured_node_count = 0;\n            match dim.size_mode {\n                SizeMode::Auto => dim.desired_size = 0.0,\n                SizeMode::Strict => dim.actual_size = dim.desired_size,\n                SizeMode::Stretch => (),\n            }\n        }\n        for handle in self.children() {\n            let Ok(node) = ui.try_get_node(*handle) else {\n                continue;\n            };\n            let Some(row) = rows.get_mut(node.row()) else {\n                Log::err(format!(\n                    \"Node row out of bounds: {} row:{}, column:{}\",\n                    node.type_info_ref().type_name,\n                    node.row(),\n                    node.column()\n                ));\n                continue;\n            };\n            let Some(col) = cols.get_mut(node.column()) else {\n                Log::err(format!(\n                    \"Node column out of bounds: {} row:{}, column:{}\",\n                    node.type_info_ref().type_name,\n                    node.row(),\n                    node.column()\n                ));\n                continue;\n            };\n            if col.size_mode == SizeMode::Auto {\n                col.unmeasured_node_count += 1","sourceCodeStart":439,"sourceCodeEnd":475,"githubUrl":"https://github.com/FyroxEngine/Fyrox/blob/76c91aad8eca488ce527b1af707be8b3b24ad72d/fyrox-ui/src/grid.rs#L439-L475","documentation":"Grid layout builds row/column measurement buckets from child nodes' row/column indices. If a child's row index is not a valid index into the grid's row definitions, this error names the node type and its row/column, and the child is skipped in layout.","triggerScenarios":"A UI node inside a Grid whose Grid::row property is >= the number of defined rows (or negative/never set while rows are explicitly defined).","commonSituations":"Setting grid row in code or editor after the grid was configured with fewer rows; building grids programmatically and forgetting to add row definitions; copy-pasted nodes retaining stale row indices.","solutions":["Set the child's row to an index within 0..rows.len()","Add enough row definitions to the Grid to cover all child row indices","Reset the child's Grid::row to the default when adding it to a new grid","Validate row/column indices programmatically when generating grid children"],"exampleFix":"// before\nchild.set_row(5); // grid only defines 3 rows\n// after\nlet row = child.row().min(grid.row_count().saturating_sub(1));\nchild.set_row(row);","handlingStrategy":"validation","validationCode":"assert!(child.row() < grid.row_count(), \"child row {} exceeds grid rows\", child.row());","typeGuard":"fn row_in_grid(child: &UiNode, grid: &Grid) -> bool { child.row() < grid.row_count() }","tryCatchPattern":null,"preventionTips":["Define grid rows before (or when) assigning child row indices","Reset Grid::row on nodes moved into a differently-sized grid","Validate generated children's row/column against grid dimensions"],"tags":["ui","layout","grid","bounds"],"backgroundTag":"index-out-of-bounds","analyzedSha":"76c91aad8eca488ce527b1af707be8b3b24ad72d","analyzedAt":"2026-09-10T16:04:01.633Z","contentChangedAt":"2026-09-10T16:04:01.633Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}