{"record":{"id":"e3542699f95a9b9d","repo":"zellij-org/zellij","slug":"changefloatingpanecoordinates-missing-pane-id","errorCode":null,"errorMessage":"ChangeFloatingPaneCoordinates missing pane_id","messagePattern":"ChangeFloatingPaneCoordinates missing pane_id","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"zellij-utils/src/ipc/protobuf_conversion.rs","lineNumber":2866,"sourceCode":"                Ok(crate::input::actions::Action::CurrentTabInfo {\n                    output_json: current_tab_info_action.output_json,\n                })\n            },\n            ActionType::TogglePanePinned(_) => Ok(crate::input::actions::Action::TogglePanePinned),\n            ActionType::StackPanes(stack_panes_action) => {\n                Ok(crate::input::actions::Action::StackPanes {\n                    pane_ids: stack_panes_action\n                        .pane_ids\n                        .into_iter()\n                        .map(|id| id.try_into())\n                        .collect::<Result<Vec<_>>>()?,\n                })\n            },\n            ActionType::ChangeFloatingPaneCoordinates(change_coords_action) => Ok(\n                crate::input::actions::Action::ChangeFloatingPaneCoordinates {\n                    pane_id: change_coords_action\n                        .pane_id\n                        .ok_or_else(|| anyhow!(\"ChangeFloatingPaneCoordinates missing pane_id\"))?\n                        .try_into()?,\n                    coordinates: change_coords_action\n                        .coordinates\n                        .ok_or_else(|| {\n                            anyhow!(\"ChangeFloatingPaneCoordinates missing coordinates\")\n                        })?\n                        .try_into()?,\n                },\n            ),\n            ActionType::TogglePaneBorderless(toggle_borderless_action) => {\n                Ok(crate::input::actions::Action::TogglePaneBorderless {\n                    pane_id: toggle_borderless_action\n                        .pane_id\n                        .ok_or_else(|| anyhow!(\"TogglePaneBorderless missing pane_id\"))?\n                        .try_into()?,\n                })\n            },\n            ActionType::SetPaneBorderless(set_borderless_action) => {","sourceCodeStart":2848,"sourceCodeEnd":2884,"githubUrl":"https://github.com/zellij-org/zellij/blob/98a0837077492d53dd252ab30bc3e43e41e504f4/zellij-utils/src/ipc/protobuf_conversion.rs#L2848-L2884","documentation":"First of two required-field checks when converting the protobuf IPC action ChangeFloatingPaneCoordinates: the action moves/reshapes a specific floating pane, so it must identify the target via the `pane_id` field. proto3 optional scalars arrive as Option in prost; if pane_id is unset the conversion fails here before coordinates are even examined.","triggerScenarios":"An IPC sender emits ChangeFloatingPaneCoordinates with only coordinates set (or fully default), omitting pane_id — the classic half-populated payload from custom clients or version-skewed stubs.","commonSituations":"Scripts programmatically repositioning floating panes; client generated from an older .proto where the field was not optional; debugging tools replaying captured actions with fields stripped.","solutions":["Set pane_id to the target pane's id (obtainable e.g. via QueryTabNames/pane-info APIs) before sending","Regenerate client stubs from the server's proto so optional-field semantics match","Align client and server zellij versions","Validate both pane_id and coordinates are present before dispatching the action"],"exampleFix":"// before\nChangeFloatingPaneCoordinatesAction { coordinates: Some(coords), ..Default::default() } // pane_id: None\n\n// after\nChangeFloatingPaneCoordinatesAction { pane_id: Some(pane_id as u64), coordinates: Some(coords) }","handlingStrategy":"validation","validationCode":"if let ActionType::ChangeFloatingPaneCoordinates(a) = action.action_type.as_ref().unwrap() {\n    if a.pane_id.is_none() {\n        anyhow::bail!(\"ChangeFloatingPaneCoordinates requires pane_id\");\n    }\n}","typeGuard":"fn change_coords_action_has_pane_id(a: &ChangeFloatingPaneCoordinatesAction) -> bool {\n    a.pane_id.is_some()\n}","tryCatchPattern":"match protobuf_action.try_into() {\n    Ok(action) => dispatch(action),\n    Err(e) if e.to_string().contains(\"missing pane_id\") => {\n        log::warn!(\"dropping pane-targeting action without pane_id\");\n    },\n    Err(e) => return Err(e.context(\"action conversion failed\")),\n}","preventionTips":["Always resolve a concrete pane id before composing pane-targeting actions","Re-fetch pane ids after layout changes; stale ids and missing ids both fail","Centralize the 'which pane?' decision in one helper that returns Option<PaneId> and bails early","Validate pane_id and coordinates together since both are required for this action"],"tags":["protobuf","ipc","action","floating-pane","pane-id","validation"],"backgroundTag":null,"analyzedSha":"98a0837077492d53dd252ab30bc3e43e41e504f4","analyzedAt":"2026-08-16T13:02:01.396Z","schemaVersion":2},"datasetVersion":"2026-08-16T13:17:31.715Z"}