CrossGeeks / GeofencePlugin

Geofence Plugin for Xamarin iOS and Android
MIT License
48 stars 22 forks source link

PendingIntent changes to Android S+ (version 31 and above) #43

Open sanjaychans opened 1 year ago

sanjaychans commented 1 year ago

Hi, I've been having the following issue since targeting the framework to 33. An alert popups up with the following message when starting monitoring and it crashes. This happens only on devices 31+.

_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 FLAGMUTABLE if some functionality depends on the PendingIntent being mutable, e.g. if it needs to be used with inline replies or bubbles.'

Running the current latest version of the plugin (1.8.1.1). I could learn from the source code that the GeofenceTransitionPendingIntent is defined with the UpdateCurrent flag which is causing the issue in 31+ I suppose.

Are there any updates that can be expected on this or is there any workaround? Any help would be highly appreciated.

Thank you.

007vel commented 8 months ago

Same issue, Any update?

BhargavSai-17 commented 2 months ago

Hi @sanjaychans, Any update regarding this issue?