braze-inc / braze-flutter-sdk

Public repo for the Braze Flutter SDK
Other
15 stars 29 forks source link

An InAppMessage is both shown nativly and processed by the flutter SDK #10

Closed JordyLangen closed 2 years ago

JordyLangen commented 2 years ago

Steps to reproduce

  1. Update to Braze 2.2.0
  2. Enable automatic integration "Streamlines the Android integration process to not involve any manual writing of code to automatically register for sessions, in-app messages, or Content Card updates from the native SDK."
  3. Start an InAppMessage campaign

Expected: The in app message is also handeld by the in app message handler

Actual: The in app message is shown using the Braze SDK itself and the in app message is also handeld by the in app message handler

Braze config:

BrazePlugin(customConfigs: {replayCallbacksConfigKey: true})..enableSDK()

I'm awaiting approval if I can share screenshots

hokstuff commented 2 years ago

Hi @JordyLangen,

Thanks for filing this issue! We have added this to our roadmap to update the implementation for the Automatic Android integration to accommodate use cases such as yours. In the meantime, you can use the workaround of setting com_braze_flutter_enable_automatic_integration_initializer to false in your Braze.xml file and continue using the manual integration.

Best, Daniel

JordyLangen commented 2 years ago

Just wondering, how is this an use case, and not a bug? I can't imagine anyone that would want to use the automatic integration and have an in app message both be shown nativly, and being handeld in their Flutter app.

Bucimis commented 2 years ago

@JordyLangen it works well for the default use case (automatic integration + native display) but as soon as a callback is added, it doesn't work anymore for the reasons you mentioned. It's effectively a bug and we should have an update to address it soon.

JordyLangen commented 2 years ago

@Bucimis do you have any idea when this fix will be in? If it's anytime soon, we'd rather wait for that fix instead of keeping the "old" manual integration.

hokstuff commented 2 years ago

Hi @JordyLangen,

We don't have a timeline around this unfortunately, but we are aiming to add this change into our next Flutter release.

Thanks!

hokstuff commented 2 years ago

Hi @JordyLangen,

We have just released Flutter SDK version 2.3.0 which allows you to restrict the Android automatic integration from displaying in-app messages. You can read more about it in our public docs which have been added to the Braze website here.

Feel free to comment with any concerns - thank you for your patience!

Best, Daniel Hok