Repository navigation
Fix startup crash when reloading extensions from a global-context provider - #342
luapmartin wants to merge 1 commit into
Conversation
| const modularity::ContextPtr& ctx = iocContext(); | ||
| if (ctx && ctx->id > 0) { | ||
| extensionsUiEngine()->clearComponentCache(); | ||
| } |
There was a problem hiding this comment.
Maybe this way is better, it's clearer
if (extensionsUiEngine) {
extensionsUiEngine()->clearComponentCache();
}
There was a problem hiding this comment.
there's no bool operator on InjectBase and if we want to use the call form then we gonna hit the asserts on ctx->id > 0
There was a problem hiding this comment.
But something isn't right here :)
ExtensionsProvider itself is also contextual.
How does it happen that it gets created, yet extensionsUiEngine doesn't?
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (1)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthrough
Priority: ➖ Normal Merge Risk: 🔵 Low · up to Only after an unusually large number of context creations can an extension reload retain stale plugin QML. This is a bounded, low-likelihood risk; merging with owner awareness is reasonable. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…context Assisted-by: Claude code
b200700 to
60da87b
Compare
|
Closing: as discussed, the provider must not be created with the global context in the first place — Audacity's |
Resolves: N/A — fixes the startup crash in audacity/audacity#12403 (all testflow cases)
Complete only if applicable:
Build configuration
audacity: audacity/audacity/master
audacity platforms: linux_x64
musescore: musescore/MuseScore/main
musescore platforms: linux_x64