-
Notifications
You must be signed in to change notification settings - Fork 1
Description
Summary
When loading a project that contains a scatterplot plugin, the application crashes on macOS and Linux. The crash does not occur on Windows.
Root Cause
The crash happens during project de-serialization.
Specifically, a UI-related function is invoked as part of the plugin’s de-serialization logic.
Calling UI code during de-serialization appears to be unsafe on macOS and Linux (likely due to threading and/or event loop constraints), and results in an application crash. On Windows this currently works, but this behavior is platform-dependent and not safe.
Technical Context
- Crash occurs while loading a saved project
- Plugin de-serialization triggers a UI function
- UI interaction during de-serialization leads to instability
Expected Behavior
Des-erialization should be:
- Pure data reconstruction
- Free of UI side effects
- Platform-independent
UI initialization or updates should occur after de-serialization, once the object is fully constructed and the UI layer is in a valid state.
Suggested Fix
Refactor the plugin so that:
- De-serialization only restores state
- UI updates are triggered in a post-de-serialization phase
(e.g., after the plugin is fully constructed and registered)
This would ensure platform-safe behavior and eliminate the crash.