CreateOpenChatActivity crashes with "channel id is empty" despite successful LineSDK.setup()
Open
Nobody has claimed this yet.
- Dominant language
- Dart
- Stars
- 225
- Forks
- 60
- PR merge metrics
- No merged PRs in 30d
Description
Environment
- Platform: Android
- flutter_line_sdk version: [2.6.2]
- Flutter version: [3.29.3]
- Android SDK: [compileSdkVersion(36)/targetSdkVersion(36)]
- LINE Channel: Verified package name
xx.xx.xx.myapp& SHA256 fingerprints match LINE Console
Current Behavior
I am sure that i run await LineSDK.instance.setup(AppConstants.lineLoginClientId) before run login() or anything
App crashes when launching CreateOpenChatActivity with stack trace from FB Crashlytics:
LineApiClientBuilder.<init>
java.lang.IllegalArgumentException - channel id is empty
Fatal Exception: java.lang.RuntimeException
Unable to start activity ComponentInfo{xx.xx.xx.myapp/com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity}: java.lang.IllegalArgumentException: channel id is empty
Fatal Exception: java.lang.RuntimeException: Unable to start activity ComponentInfo{xx.xx.xx.myapp/com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity}: java.lang.IllegalArgumentException: channel id is empty
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3645)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3782)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:101)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2307)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:201)
at android.os.Looper.loop(Looper.java:288)
at android.app.ActivityThread.main(ActivityThread.java:7872)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
Caused by java.lang.IllegalArgumentException
channel id is empty
Caused by java.lang.IllegalArgumentException: channel id is empty
at com.linecorp.linesdk.api.LineApiClientBuilder.<init>(LineApiClientBuilder.java:42)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity$lineApiClient$2.invoke(CreateOpenChatActivity.kt:30)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity$lineApiClient$2.invoke(CreateOpenChatActivity.kt:28)
at kotlin.SynchronizedLazyImpl.getValue(LazyJVM.kt:86)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity.getLineApiClient(CreateOpenChatActivity.kt:28)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity.access$getLineApiClient(CreateOpenChatActivity.kt:25)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity$initViewModel$1.create(CreateOpenChatActivity.kt:59)
at androidx.lifecycle.ViewModelProvider$Factory.create(ViewModelProvider.android.kt)
at androidx.lifecycle.ViewModelProvider$Factory.create(ViewModelProvider.android.kt:158)
at androidx.lifecycle.viewmodel.ViewModelProviderImpl_androidKt.createViewModel(ViewModelProviderImpl_android.kt:34)
at androidx.lifecycle.viewmodel.ViewModelProviderImpl.getViewModel$lifecycle_viewmodel_release(ViewModelProviderImpl.java:65)
at androidx.lifecycle.viewmodel.ViewModelProviderImpl.getViewModel$lifecycle_viewmodel_release$default(ViewModelProviderImpl.java:47)
at androidx.lifecycle.ViewModelProvider.get(ViewModelProvider.java:91)
at androidx.lifecycle.ViewModelProvider.get(ViewModelProvider.java:109)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity.initViewModel(CreateOpenChatActivity.kt:54)
at com.linecorp.linesdk.openchat.ui.CreateOpenChatActivity.onCreate(CreateOpenChatActivity.kt:42)
at android.app.Activity.performCreate(Activity.java:8305)
at android.app.Activity.performCreate(Activity.java:8284)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1417)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3626)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3782)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:101)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2307)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:201)
at android.os.Looper.loop(Looper.java:288)
at android.app.ActivityThread.main(ActivityThread.java:7872)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
Here is my outputs from fvm flutter doctor -v command
[✓] Flutter (Channel stable, 3.29.3, on macOS 26.2 25C56 darwin-arm64, locale en-VN) [290ms]
• Flutter version 3.29.3 on channel stable at /Users/splus/fvm/versions/3.29.3
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision ea121f8859 (10 months ago), 2025-04-11 19:10:07 +0000
• Engine revision cf56914b32
• Dart version 3.7.2
• DevTools version 2.42.3
[✓] Android toolchain - develop for Android devices (Android SDK version 36.0.0) [1,113ms]
• Android SDK at /Users/splus/Library/Android/sdk
• Platform android-36, build-tools 36.0.0
• ANDROID_HOME = /Users/splus/Library/Android/sdk
• Java binary at: /Library/Java/JavaVirtualMachines/jdk-17.jdk/Contents/Home/bin/java
This JDK is specified in your Flutter configuration.
To change the current JDK, run: `flutter config --jdk-dir="path/to/jdk"`.
• Java version Java(TM) SE Runtime Environment (build 17.0.12+8-LTS-286)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 26.2) [577ms]
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 17C52
• CocoaPods version 1.16.2
[✓] Chrome - develop for the web [34ms]
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2025.2) [34ms]
• 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 21.0.8+-14196175-b1038.72)
[✓] IntelliJ IDEA Ultimate Edition (version 2025.3) [33ms]
• IntelliJ at /Applications/IntelliJ IDEA.app
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin version 500.0.0
[✓] VS Code (version 1.106.3) [7ms]
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.126.0
[✓] Connected device (6 available) [5.9s]
[✓] Network resources [1,138ms]
• All expected network resources are available.
• No issues found!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Trace the Flutter setup path and the Android CreateOpenChatActivity.kt call sites shown in the stack trace, then inspect how the channel ID reaches LineApiClientBuilder. Reproduce the crash with flutter_line_sdk 2.6.2 and the reported Flutter and Android versions; done means CreateOpenChatActivity launches without the empty-channel-id exception.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, dart, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100