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

Exception on Android 12 / S #634

Closed
harry248 opened this issue Jun 9, 2021 · 7 comments
Closed

Exception on Android 12 / S #634

harry248 opened this issue Jun 9, 2021 · 7 comments
Assignees
Labels
bug Something isn't working

Comments

@harry248
Copy link

harry248 commented Jun 9, 2021

✍️ Describe the bug

On Android 12 chucker causes a crash due to a missing intent flag.

💣 Steps to reproduce

Bump compile/target sdk to Android S and try any app using chucker.

🔧 Expected behavior

Chucker doesn't crash the app.

📱 Tech info

  • Device: Pixel 4a
  • OS: Android 12 Beta 1
  • Chucker version: 3.4.0

📄 Additional context

java.lang.IllegalArgumentException: de.ocm.app.dev: Targeting S+ (version 10000 and above) requires that one of FLAG_IMMUTABLE or FLAG_MUTABLE be specified when creating a PendingIntent.
Strongly consider using FLAG_IMMUTABLE, only use FLAG_MUTABLE if some functionality depends on the PendingIntent being mutable, e.g. if it needs to be used with inline replies or bubbles.
at android.app.PendingIntent.checkFlags(PendingIntent.java:386)
at android.app.PendingIntent.getActivityAsUser(PendingIntent.java:470)
at android.app.PendingIntent.getActivity(PendingIntent.java:456)
at android.app.PendingIntent.getActivity(PendingIntent.java:420)
at com.chuckerteam.chucker.internal.support.NotificationHelper$transactionsScreenIntent$2.invoke(SourceFile:47)
at com.chuckerteam.chucker.internal.support.NotificationHelper$transactionsScreenIntent$2.invoke(SourceFile:19)
at kotlin.SynchronizedLazyImpl.getValue(SourceFile:74)
at com.chuckerteam.chucker.internal.support.NotificationHelper.getTransactionsScreenIntent(Unknown Source:2)
at com.chuckerteam.chucker.internal.support.NotificationHelper.show(SourceFile:101)
at com.chuckerteam.chucker.api.ChuckerCollector.onRequestSent$com_github_ChuckerTeam_Chucker_library(SourceFile:65)
at com.chuckerteam.chucker.api.ChuckerInterceptor.intercept(SourceFile:111)

@vbuberen
Copy link
Collaborator

vbuberen commented Jun 9, 2021

Hey @harry248
Thanks for reporting this issue. We already have it resolved in our snapshot version: https://github.com/ChuckerTeam/chucker#snapshots-
Please give it a try and let me know if it works fine.
We will try to cut a new 3.4.1 stable release for Android 12 users in nearest time. Need just to pick non-breaking commits there.

@vbuberen vbuberen added the bug Something isn't working label Jun 9, 2021
@vbuberen vbuberen self-assigned this Jun 9, 2021
@vbuberen
Copy link
Collaborator

vbuberen commented Jun 29, 2021

@harry248 We have just released 3.5.0 with the fix for the issue you reported. Feel free to check it out and let us know how it is going.

https://github.com/ChuckerTeam/chucker/releases/tag/3.5.0

@saramace
Copy link

saramace commented Jul 14, 2021

Hi @vbuberen Just wanted to let you know that I believe one pending intent was missed here: 515b3f0#diff-c5132152b8a29a93267e2854e720cc1c911da352603166ab6b8c8a64caba9059R60 specifically this line

I noticed it doesn't exist in the latest snapshot version and am trying the snapshot out but having trouble using it in my project due to it being a major release with more changes

@cortinico
Copy link
Member

I noticed it doesn't exist in the latest snapshot version and am trying the snapshot out but having trouble using it in my project due to it being a major release with more changes

You're right @saramace, thanks for reporting. The fix is here: #653

@saramace
Copy link

Thank you so much for the fast fix!

@saramace
Copy link

Would it be posibile to get 3.5.1 promoted from stage to prod

I noticed the steps just have it go to stage: https://github.com/ChuckerTeam/chucker/runs/3107658830?check_suite_focus=true and its not yet showing in maven central: https://search.maven.org/artifact/com.github.chuckerteam.chucker/library

@vbuberen
Copy link
Collaborator

Yeah, it looks like we forgot to promote the release.
We just did it, so in a few hours 3.5.1 should be available on Maven central.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants