Skip to content
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: Catch null content errors #21673

Merged
merged 3 commits into from
Feb 7, 2025
Merged

Conversation

dcalhoun
Copy link
Member

@dcalhoun dcalhoun commented Feb 7, 2025

There are contexts where the JavaScript runtime appears to send null
values to the host app. It could be performance related, but we should
catch the errors nonetheless.

Related:

To Test:

I was unable to reproduce the crash, so we cannot test the fix. We can test for regressions in the form of saving title and content changes in the editor—save/update button, back button, quit app, etc.

Regression Notes

  1. Potential unintended areas of impact
    None likely.
  2. What I did to test those areas of impact (or what existing automated tests I relied on)
    Testing saving title and content changes.
  3. What automated tests I added (or what prevented me from doing so)
    Deemed unnecessary for the experimental feature.

PR Submission Checklist:

  • I have completed the Regression Notes.
  • I have considered adding accessibility improvements for my changes.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

Testing Checklist (strike-out the not-applying and unnecessary ones):

  • WordPress.com sites and self-hosted Jetpack sites.
  • Portrait and landscape orientations.
  • Light and dark modes.
  • Fonts: Larger, smaller and bold text.
  • High contrast.
  • Talkback.
  • Languages with large words or with letters/accents not frequently used in English.
  • Right-to-left languages. (Even if translation isn’t complete, formatting should still respect the right-to-left layout)
  • Large and small screen sizes. (Tablet and smaller phones)
  • Multi-tasking: Split screen and Pop-up view. (Android 10 or higher)

There are contexts where the JavaScript runtime appears to send null
values to the host app. It could be performance related, but we should
catch the errors nonetheless.
@dcalhoun dcalhoun added [Type] Crash Gutenberg Editing and display of Gutenberg blocks. labels Feb 7, 2025
@dangermattic
Copy link
Collaborator

dangermattic commented Feb 7, 2025

1 Warning
⚠️ PR is not assigned to a milestone.

Generated by 🚫 Danger

@wpmobilebot
Copy link
Contributor

wpmobilebot commented Feb 7, 2025

Project dependencies changes

The following changes in project dependencies were detected (configuration wordpressVanillaReleaseRuntimeClasspath):

list
Upgraded Dependencies
org.wordpress.gutenbergkit:android:trunk-7894ff454cf2a889dd4634e031c1a0323d7f3d08, (changed from trunk-7a9a66ce400ef1baaa2d098c0f8c95ffe1f42f81)
tree
 +--- project :libs:editor
-|    \--- org.wordpress.gutenbergkit:android:trunk-7a9a66ce400ef1baaa2d098c0f8c95ffe1f42f81
+|    \--- org.wordpress.gutenbergkit:android:trunk-7894ff454cf2a889dd4634e031c1a0323d7f3d08
-\--- org.wordpress.gutenbergkit:android:trunk-7a9a66ce400ef1baaa2d098c0f8c95ffe1f42f81 (*)
+\--- org.wordpress.gutenbergkit:android:trunk-7894ff454cf2a889dd4634e031c1a0323d7f3d08 (*)

@wpmobilebot
Copy link
Contributor

wpmobilebot commented Feb 7, 2025

WordPress📲 You can test the changes from this Pull Request in WordPress by scanning the QR code below to install the corresponding build.
App NameWordPress WordPress
FlavorJalapeno
Build TypeDebug
Versionpr21673-3c28b1a
Commit3c28b1a
Direct Downloadwordpress-prototype-build-pr21673-3c28b1a.apk
Note: Google Login is not supported on these builds.

@wpmobilebot
Copy link
Contributor

wpmobilebot commented Feb 7, 2025

Jetpack📲 You can test the changes from this Pull Request in Jetpack by scanning the QR code below to install the corresponding build.
App NameJetpack Jetpack
FlavorJalapeno
Build TypeDebug
Versionpr21673-3c28b1a
Commit3c28b1a
Direct Downloadjetpack-prototype-build-pr21673-3c28b1a.apk
Note: Google Login is not supported on these builds.

@dcalhoun dcalhoun marked this pull request as ready for review February 7, 2025 19:56
@dcalhoun dcalhoun requested a review from nbradbury February 7, 2025 19:56
@dcalhoun dcalhoun added the Do Not Merge In PRs with this label, our automation will fail a require check, preventing accidental merging label Feb 7, 2025
@nbradbury nbradbury self-assigned this Feb 7, 2025
Copy link
Contributor

@nbradbury nbradbury left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dcalhoun This all tested fine, merge when ready :shipit:

@dcalhoun dcalhoun removed the Do Not Merge In PRs with this label, our automation will fail a require check, preventing accidental merging label Feb 7, 2025
@dcalhoun dcalhoun enabled auto-merge (squash) February 7, 2025 20:28
Copy link

sonarqubecloud bot commented Feb 7, 2025

@dcalhoun dcalhoun merged commit 47de005 into trunk Feb 7, 2025
20 of 23 checks passed
@dcalhoun dcalhoun deleted the fix/catch-null-content-errors branch February 7, 2025 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Gutenberg Editing and display of Gutenberg blocks. [Type] Crash
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants