Skip to content

MacOS crash on PFP -> Side menu Accounts #1270

@alltheseas

Description

@alltheseas
 Widget layer_id change panic when navigating to Accounts                                                                                                                                
                                                                                                                                                                                          
  Description                                                                                                                                                                             
                                                                                                                                                                                          
  The app crashes with a panic when navigating to the Accounts screen via the side menu (PFP → Accounts).                                                                                 
                                                                                                                                                                                          
  Steps to Reproduce                                                                                                                                                                      
                                                                                                                                                                                          
  1. Launch notedeck                                                                                                                                                                      
  2. Click on profile picture (PFP) to open side menu                                                                                                                                     
  3. Click "Accounts" in the side menu                                                                                                                                                    
  4. App crashes                                                                                                                                                                          
                                                                                                                                                                                          
  Error Message                                                                                                                                                                           
                                                                                                                                                                                          
  thread 'main' panicked at egui/src/widget_rect.rs:163:17:                                                                                                                               
  Widget 2CF4 changed layer_id during the frame from LayerId { Background 2CF4 } to LayerId { Foreground F4DF }                                                                           
                                                                                                                                                                                          
  Stack Trace (relevant frames)                                                                                                                                                           
                                                                                                                                                                                          
  egui::widget_rect::WidgetRects::insert                                                                                                                                                  
  egui::context::Context::create_widget                                                                                                                                                   
  egui::ui::Ui::remember_min_rect                                                                                                                                                         
  <egui::ui::Ui as core::ops::drop::Drop>::drop                                                                                                                                           
  egui::ui::Ui::new                                                                                                                                                                       
  egui_nav::render_fg (lib.rs:529)                                                                                                                                                        
  egui_nav::Nav<Route>::show_internal (lib.rs:357)                                                                                                                                        
  notedeck_columns::nav::render_nav (nav.rs:1185)                                                                                                                                         
  notedeck_columns::app::timelines_view (app.rs:907)                                                                                                                                      
                                                                                                                                                                                          
  Environment                                                                                                                                                                             
                                                                                                                                                                                          
  - Platform: macOS (Darwin 25.2.0)                                                                                                                                                       
  - Build: debug profile                                                                                                                                                                  
  - Branch: calendar-features (but crash reproduces on master)                                                                                                                            
                                                                                                                                                                                          
  Analysis                                                                                                                                                                                
                                                                                                                                                                                          
  The crash occurs in egui's widget rect tracking when a widget changes its layer_id mid-frame. This appears to be triggered during navigation transitions in egui_nav when rendering     
  foreground/background layers. The issue is in the interaction between render_fg and render_bg in egui_nav, where a UI element is being created in one layer context but finalized in    
  another.                                                                                                                                                                                
                                                                                                                                                                                          
  Possibly Related                                                                                                                                                                        
                                                                                                                                                                                          
  - egui_nav layer management during drawer transitions                                                                                                                                   
  - Navigation to routes that trigger different layer contexts                  


 Version: 0.7.1                                                                                                                                                                          
  Commit: e1ec8ae6 (header: skip hide animation on wide screens)                                                                                                                          
                                                                                                                                                                                          
  Add to issue:                                                                                                                                                                           
                                                                                                                                                                                          
  ### Version                                                                                                                                                                             
                                                                                                                                                                                          
  - notedeck: 0.7.1                                                                                                                                                                       
  - Commit: e1ec8ae6 (master)                                                                                                                                                             
                            

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions