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

Targeting S+ (version 31 and above) requires that one of FLAG_IMMUTABLE or FLAG_MUTABLE be specified #315

Open
HLI5KY opened this issue Oct 8, 2023 · 1 comment

Comments

@HLI5KY
Copy link

HLI5KY commented Oct 8, 2023

App crashes at runtime with the following error :

java.lang.IllegalArgumentException: de.rampro.activitydiary: Targeting S+ (version 31 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:404)
	at android.app.PendingIntent.getActivityAsUser(PendingIntent.java:487)
	at android.app.PendingIntent.getActivity(PendingIntent.java:473)
	at android.app.PendingIntent.getActivity(PendingIntent.java:437)
	at de.rampro.activitydiary.helpers.ActivityHelper.showCurrentActivityNotification(ActivityHelper.java:457)
	at de.rampro.activitydiary.helpers.ActivityHelper.setCurrentActivity(ActivityHelper.java:424)
	at de.rampro.activitydiary.ui.main.MainActivity.onItemClick(MainActivity.java:367)
	at de.rampro.activitydiary.ui.main.SelectViewHolders.onClick(SelectViewHolders.java:50)
	at android.view.View.performClick(View.java:7545)
	at android.view.View.performClickInternal(View.java:7522)
	at android.view.View.-$$Nest$mperformClickInternal(Unknown Source:0)
	at android.view.View$PerformClick.run(View.java:29562)
	at android.os.Handler.handleCallback(Handler.java:942)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:210)
	at android.os.Looper.loop(Looper.java:299)
	at android.app.ActivityThread.main(ActivityThread.java:8235)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:559)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:954)
@ramack
Copy link
Owner

ramack commented Oct 8, 2023

Thanks for reporting. I am really way behind in the development of this app and should release an update.

@ramack ramack added this to the v1.5.0 milestone Oct 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants