-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix ClassCastException caused by assuming editorFragment was a Gutenb… #21665
Conversation
…ergEditorFragment when it could be a GutenbergKitEditorFragment
Generated by 🚫 Danger |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. These testing plan succeeded for me, the crash no longer occurs. Thank you for addressing this! 🙇🏻♂️
This crash started happening with 25.6, but given this is an experimental feature I wasn't sure if a hotfix was necessary.
Given the 25.6.1
release has not shipped, I suggest we include this in both the 25.6.1
and 25.7
releases. This crash could occur at any point if a user's network connection intermittently disconnects.
|
App Name | ![]() |
|
Flavor | Jalapeno | |
Build Type | Debug | |
Version | pr21665-8d33633 | |
Commit | 8d33633 | |
Direct Download | wordpress-prototype-build-pr21665-8d33633.apk |
👍 I'll work on PRs for both of these. |
|
App Name | ![]() |
|
Flavor | Jalapeno | |
Build Type | Debug | |
Version | pr21665-8d33633 | |
Commit | 8d33633 | |
Direct Download | jetpack-prototype-build-pr21665-8d33633.apk |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## trunk #21665 +/- ##
=======================================
Coverage 39.42% 39.42%
=======================================
Files 2122 2122
Lines 99558 99558
Branches 15317 15317
=======================================
Hits 39247 39247
Misses 56832 56832
Partials 3479 3479 ☔ View full report in Codecov by Sentry. |
Closes #21664
This PR fixes a
ClassCastException
caused by assumingeditorFragment
was aGutenbergEditorFragment
when it could be aGutenbergKitEditorFragment
in this code:Since both of these fragments extend
GutenbergNetworkConnectionListener
we simply needed to change this to a safe cast for that listener.@dcalhoun This crash started happening with 25.6, but given this is an experimental feature I wasn't sure if a hotfix was necessary.
To test: