agentsclimarketplace

Cometchat android v5 troubleshooting

Skill cometchat/cometchat-skills/skills/cometchat-android-v5-troubleshooting

Add CometChat chat & messaging and voice & video calls to any React, Next.js, React Native, Angular, Android, iOS, or Flutter project through your AI coding agent. Works with Claude Code, Cursor, Codex, VS Code Copilot, Windsurf, Cline, Kiro, and 50+ more agents.

Install
npx -y skills add cometchat/cometchat-skills --skill cometchat-android-v5-troubleshooting

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.

What its author says it does

Copied from the file, not written here

Diagnose and fix problems with a CometChat Android integration. Gradle errors, runtime crashes, rendering issues, and version compatibility.

The file declares its own license as MIT. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

4.3 KB, as published. Nobody here has run it

Ground truth: com.cometchat:chat-uikit-android:5.x (legacy/maintenance-only; +calls-sdk-android:5.x) — resolved AAR (javap) + ui-kit/android. Official docs: https://www.cometchat.com/docs/ui-kit/android/overview · Docs MCP: claude mcp add --transport http cometchat-docs https://www.cometchat.com/docs/mcp (or fetch the URL directly without MCP). Verify symbols against the installed package/source before relying on them.

Companion skills: cometchat-android-v5-core covers correct init/login patterns; cometchat-android-v5-production covers ProGuard rules.

Purpose

This skill teaches how to diagnose CometChat Android integration problems systematically. It covers Gradle build errors, runtime crashes, rendering issues, and version compatibility.


Use this skill when

  • "CometChat isn't working"
  • "I'm getting a build error"
  • "The chat screen is blank"
  • "Messages aren't loading"
  • Gradle sync failures
  • Runtime crashes with CometChat in the stack trace

Do not use this skill when

  • Setting up a new integration → use cometchat-android-v5-core
  • Customizing appearance → use cometchat-android-v5-theming

1. Common issues

SymptomLikely causeFix
Could not resolve com.cometchat:chat-uikit-androidMissing Maven repoAdd maven { url "https://dl.cloudsmith.io/public/cometchat/cometchat/maven/" } to repositories
Duplicate class com.cometchat.*Multiple CometChat versionsCheck dependency tree: ./gradlew app:dependencies
Blank conversation listNot logged in, or no conversations existVerify getLoggedInUser() != null. Send a test message from dashboard.
CometChatException: ERR - Authentication nullinit() not called or failedCall init() before login(). Check isSDKInitialized().
CometChatException: appIdErrApp ID not set in UIKitSettingsVerify setAppId() in UIKitSettingsBuilder
Components show but no dataLogin succeeded but wrong regionVerify region matches dashboard: "us", "eu", "in"
ClassNotFoundException in release buildProGuard stripping CometChat classesAdd -keep class com.cometchat.** { *; } to proguard-rules.pro
UnsupportedOperationException: Failed to resolve attribute when inflating CometChat viewsApp theme inherits Theme.AppCompat.* or Theme.Material3.* — the kit's attrs are resolved against Material 2 (CometChatTheme.DayNight itself parents on Theme.MaterialComponents.DayNight.NoActionBar)Change app theme parent to CometChatTheme.DayNight
NetworkOnMainThreadExceptionCalling CometChat sync methods on main threadUse callbacks (all CometChat methods are async)
minSdkVersion 21 errorCometChat requires API 24+Set minSdkVersion 24 in build.gradle
Message list shows wrong messagessetUser()/setGroup() called with wrong objectVerify UID/GUID matches the intended conversation
Calling buttons not showingCalling SDK not addedAdd com.cometchat:calls-sdk-android:5.+ dependency (matches -core/-features)
java.lang.NoSuchMethodErrorVersion mismatch between UI Kit and Chat SDKUse compatible versions — UI Kit 5.x requires Chat SDK 4.x

2. Diagnostic steps

  1. Check init: CometChatUIKit.isSDKInitialized() — must be true
  2. Check login: CometChatUIKit.getLoggedInUser() — must not be null
  3. Check Gradle: ./gradlew app:dependencies | grep cometchat — verify versions
  4. Check manifest: Verify INTERNET permission
  5. Check region: Must match dashboard exactly
  6. Check logs: Filter logcat for CometChat tag

Hard rules

  • Always check init + login first. 90% of "it's not working" issues are init/login failures.
  • Never guess at the cause. Check logcat, check the dependency tree, check the dashboard.
  • ProGuard is the #1 release-build issue. Always add keep rules before the first release build.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.