CleverTap / clevertap-flutter

CleverTap Flutter SDK
Other
30 stars 42 forks source link

Custom notification not showing when app in kill state. #239

Open lokesh-univest opened 1 month ago

lokesh-univest commented 1 month ago

I am using clevertap_plugin: ^2.2.0 in flutter. And I am using following flutter version:

[✓] Flutter (Channel stable, 3.16.7, on macOS 14.4.1 23E224 darwin-arm64, locale en-IN)
    • Flutter version 3.16.7 on channel stable at /Users/lkrjangid/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision ef1af02aea (4 months ago), 2024-01-11 15:19:26 -0600
    • Engine revision 4a585b7929
    • Dart version 3.2.4
    • DevTools version 2.28.5

[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /Users/lkrjangid/Library/Android/sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.10+0-17.0.10b1087.21-11572160)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.3)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15E204a
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2023.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.10+0-17.0.10b1087.21-11572160)

[✓] Connected device (4 available)            
    • motorola edge 40 neo (mobile) • 192.168.0.87:5555 • android-arm64  • Android 13 (API 33)
    • sdk gphone64 arm64 (mobile)   • emulator-5560     • android-arm64  • Android 14 (API 34) (emulator)
    • macOS (desktop)               • macos             • darwin-arm64   • macOS 14.4.1 23E224 darwin-arm64
    • Chrome (web)                  • chrome            • web-javascript • Google Chrome 125.0.6422.76
    ! Device emulator-5556 is offline.
    ! Device emulator-5558 is offline.

[✓] Network resources
    • All expected network resources are available.

• No issues found!

When my app in kill state and any custom notification came to app it's shows that notification as simple notification not as custom notification. But when my app in background or foreground state it's working fine.

I have followed https://github.com/CleverTap/clevertap-android-sdk/blob/master/docs/CTPUSHTEMPLATES.md#template-keys and https://github.com/CleverTap/clevertap-flutter/tree/master/doc docs for setup my application.

CTLalit commented 1 month ago

untitled-flutter.webm

@lokesh-univest As it can be seen in the sample app we tried to send a carousel template and it seems to be working fine in killed state as well.

We will need further details from your end :

  1. share the payload you are sending which is misbehaving in killed state. (If the payload is incorrect there are cases in SDK where it fallbacks to basic template)
  2. can you share the campaign link which is used to configure this PT
  3. Logs (in verbose mode) after reproducing the issue
  4. Do you have custom implementation of FCM service in your app, if yes; then please share the how you initiate PT flow.