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 deep link auto play crash #2812

Merged
merged 1 commit into from
Sep 8, 2024
Merged

Fix deep link auto play crash #2812

merged 1 commit into from
Sep 8, 2024

Conversation

MiSikora
Copy link
Contributor

@MiSikora MiSikora commented Sep 7, 2024

Description

I've noticed this issue in Sentry. It is related to my changes introducing auto play through deep link. When trying to avoid auto playing on configuration changes I inadvertently prevented view model from being set up after process death.

Testing Instructions

Fix

  1. Start the app.
  2. Go to any episode details.
  3. Minimize the app.
  4. Run adb shell am kill au.com.shiftyjelly.pocketcasts.debug.
  5. Reopen the app.
  6. There should be no crash.

Auto play

  1. Run adb shell am start -n au.com.shiftyjelly.pocketcasts.debug/au.com.shiftyjelly.pocketcasts.ui.MainActivity -a android.intent.action.VIEW -d "https://pca.st/episode/49900dc4-d6de-4673-b894-2da321b307d0?auto_play=true"
  2. The episode should start playing.
  3. Pause the episode in the episode details view.
  4. Rotate the screen.
  5. The episode should not start playing again.
  6. Run again adb shell am start -n au.com.shiftyjelly.pocketcasts.debug/au.com.shiftyjelly.pocketcasts.ui.MainActivity -a android.intent.action.VIEW -d "https://pca.st/episode/49900dc4-d6de-4673-b894-2da321b307d0?auto_play=true".
  7. The episode should start playing again.
  8. Pause the episode.
  9. Minimize the app.
  10. Run adb shell am kill au.com.shiftyjelly.pocketcasts.debug.
  11. Reopen the app.
  12. The episode should not start playing.

Checklist

  • If this is a user-facing change, I have added an entry in CHANGELOG.md
  • Ensure the linter passes (./gradlew spotlessApply to automatically apply formatting/linting)
  • I have considered whether it makes sense to add tests for my changes
  • All strings that need to be localized are in modules/services/localization/src/main/res/values/strings.xml
  • Any jetpack compose components I added or changed are covered by compose previews
  • I have updated (or requested that someone edit) the spreadsheet to reflect any new or changed analytics.

I have tested any UI changes...

  • with different themes
  • with a landscape orientation
  • with the device set to have a large display and font size
  • for accessibility with TalkBack

@MiSikora MiSikora added [Type] Bug Not functioning as intended. [Area] Playback Episode playback issue labels Sep 7, 2024
@MiSikora MiSikora added this to the 7.72 ❄️ milestone Sep 7, 2024
@MiSikora MiSikora requested a review from a team as a code owner September 7, 2024 09:48
@MiSikora MiSikora requested review from ashiagr and removed request for a team September 7, 2024 09:48
@dangermattic
Copy link
Collaborator

dangermattic commented Sep 7, 2024

1 Warning
⚠️ This PR is assigned to the milestone 7.72 ❄️. The due date for this milestone has already passed.
Please assign it to a milestone with a later deadline or check whether the release for this milestone has already been finished.

Generated by 🚫 Danger

@MiSikora MiSikora added the [Priority] High Requires immediate attention label Sep 7, 2024
@wpmobilebot
Copy link
Collaborator

wpmobilebot commented Sep 7, 2024

📲 You can test the changes from this Pull Request in 📱 Mobile by scanning the QR code below to install the corresponding build.
App Name 📱 Mobile
Build TypedebugProd
Commit4a49bee
Direct Downloadpocketcasts-app-prototype-build-pr2812-4a49bee.apk
📲 You can test the changes from this Pull Request in 🚗 Automotive by scanning the QR code below to install the corresponding build.
App Name 🚗 Automotive
Build TypedebugProd
Commit4a49bee
Direct Downloadpocketcasts-automotive-prototype-build-pr2812-4a49bee.apk
📲 You can test the changes from this Pull Request in ⌚ Wear by scanning the QR code below to install the corresponding build.
App Name ⌚ Wear
Build TypedebugProd
Commit4a49bee
Direct Downloadpocketcasts-wear-prototype-build-pr2812-4a49bee.apk

@ashiagr ashiagr merged commit 9cf8ee9 into release/7.72 Sep 8, 2024
16 of 18 checks passed
@ashiagr ashiagr deleted the fix/lateinit-crash branch September 8, 2024 07:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Area] Playback Episode playback issue [Priority] High Requires immediate attention [Type] Bug Not functioning as intended.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants