https://kotlinlang.org logo
Join Slack
Powered by
# android
  • i

    Ivan

    05/18/2025, 4:37 PM
    Hello all 🙂 has anyone tried to run a kotlin notebook with an android kernel ? 🤔 I use android libs like google's ML-Kit , and I thought prototyping would be super simple if I could run a notebook with an Android emulator behind. Any clues? I haven't seen anything like this on internet. THX
    👀 3
    u
    • 2
    • 1
  • g

    Godwise

    05/21/2025, 9:17 PM
    set the channel topic: K android new Using Kotlin to build Android apps. Avoid not kotlin but kotlin colored . not kotlin but kotlin colored should go to: https://discord.com/invite/D2cNrqX http://android-united.community/
    👍 4
  • f

    Filippo De Pretto

    05/27/2025, 2:47 PM
    Hi guys 🙂 I'm trying to do a pre-registration of our app for the italian country, but Italy is weirdly not available among the options for pre-registration. Do you have any idea why is this happening?
    not kotlin but kotlin colored 4
    c
    • 2
    • 2
  • k

    Kevin

    05/27/2025, 7:13 PM
    Kotlin bench result - Instacart principle android engineer (Kaushik Gopal) discussing claude 4 opus/sonnet ability to write kotlin code https://x.com/kaushikgopal/status/1926022918829461830
    c
    f
    • 3
    • 4
  • d

    Den Drobiazko

    05/27/2025, 9:37 PM
    Greetings, fellow colleagues! TLDR: I am facing a rather niche issue after updating AGP from 8.3.2 to 8.8.2 in our multimodule project, which we use to release a certain SDK. This issue is possibly related to a newer R8 being bundled with newer AGP. The details are in a thread message. Thank you!
    🧵 2
    c
    z
    t
    • 4
    • 7
  • s

    Satyam Gondhale

    05/28/2025, 12:31 PM
    What libraries we can use for livedata and viewmodel in KMM if we are having desktop android and web support. Any help will be appreciated
    c
    • 2
    • 3
  • z

    zak.taccardi

    05/28/2025, 6:46 PM
    com.android.builder.model.Version.ANDROID_GRADLE_PLUGIN_VERSION
    is deprecated, with a
    use com.android.VERSION instead
    - but I don't see it on the class path at all. What am I missing? Use case is to check the current AGP version programmatically
    not kotlin but kotlin colored 4
    c
    e
    • 3
    • 2
  • a

    Anuj Chahal

    05/30/2025, 3:51 PM
    I am a beginner, so which platform is better for android development a) IntelliJ IDEA b) Android Studio
    not kotlin but kotlin colored 3
    r
    a
    +2
    • 5
    • 8
  • s

    Satyam Gondhale

    06/02/2025, 11:32 AM
    Does anyone have working solution on this problem. I am facing it. I have a multi module project with kotlin multiplatform https://youtrack.jetbrains.com/issue/KT-33191/JS-Gradle-plugin-applies-BasePlugin-to-the[…]ses-build-configuration-fail-in-case-of-custom-clean-task
    c
    a
    • 3
    • 7
  • s

    Slackbot

    06/05/2025, 9:11 AM
    This message was deleted.
    ❌ 1
    g
    n
    • 3
    • 2
  • a

    Amir Golmoradi

    06/06/2025, 10:44 AM
    Hi, I want to learn Android development ( Kotlin, Compose, etc ). Can you recommend videos, tutorials, or other resources to help? About myself i can say that: I'm Mid-Level Java Backend dev. I have experience in android development with Flutter
    a
    p
    • 3
    • 6
  • d

    David Bauer

    06/07/2025, 6:17 AM
    I just updated to AS Narwhal Feature Drop | 2025.1.2 Canary 4 and got this "Plugin 'Kotlin Multiplatform' (version 0.9-251.25410-AS-69) was explicitly marked as incompatible with the current version of the IDE" I though the Plugin comes now as part of the IDE, so how come the IDE version is released with an incompatible KMP plugin?
    ➕ 4
  • a

    Angelyn

    06/07/2025, 7:16 PM
    Hi! I'm Angelyn and I just joined. 🤗 Anyone going to droidcon in NYC this month? https://nyc.droidcon.com/
    not kotlin but kotlin colored 3
    c
    • 2
    • 3
  • a

    Angelyn

    06/07/2025, 7:17 PM
    I'm super excited about it! 😆
    🧵 2
  • t

    Tower Guidev2

    06/09/2025, 12:19 PM
    Hi i am using
    android.webkit.WebView
    to show web content from within my application i have a usecase where i need to detect if my users download a file while they are browsing i cannot see any associated callbacks that support this functionallity is there any way to detect a user initiated download and what file they are downloading?
    not kotlin but kotlin colored 4
    c
    p
    • 3
    • 2
  • e

    Edwin

    06/10/2025, 9:52 PM
    Hi Everyone, I hope anyone could help me dealing with a bug related to Koin dependencies in an Android Project. The app crashes when the app is starting... but it doesn't happen always. It's random when it happens and only in Production. When running the app in Debug, it works fine. We got a firebase track log from prod... here it is:
    Copy code
    Caused by: org.koin.core.error.InstanceCreationException: Could not create instance for '[Singleton: 'com...UpdateInteractor']'
    base on the full trace log, it seems to be triggered by a dependency required on
    MainActivity -> onStart()
    But I have all the injectors well defined on the Koin modules. After a lot of back and forth... I found a way to reproduce similar issue in debug env, which is in the Koin module class, when creating the module setting the parameter
    createdAtStart = true
    (by default false), it makes the app crash when it's starting... throwing similar trace log than prod. It seems to be like a race condition issue, but still figuring out what is the real cause of that. If anyone have faced any similar issue dealing with Koin dependencies, I would appreciate any help. I found someone here in the past faced similar issue, but didn't post any solution.
    j
    • 2
    • 1
  • s

    Sargun Vohra

    06/11/2025, 8:48 PM
    Hey folks, I've got an incredibly simple Compose Multiplatform demo app for my library, and for some reason when I run the Android build for this demo, the network calls cause the UI to stutter, as if they're blocking the main thread. I'm making the network call using a
    suspend fun
    in a
    LaunchedEffect
    , and the client is backed by Ktor (via Ktorfit) and the OkHttp engine. As far as I can tell, these network calls shouldn't be blocking the main thread, but still the UI stutters when I scroll (triggering network calls as list items load). The problem only happens on Android. The demo on iOS, Desktop (JVM), macOS (native), JS, and WASM builds all have a totally smooth UI. I've tried: • Explicitly setting
    <http://Dispatchers.IO|Dispatchers.IO>
    ◦ No change. Verified in Ktor source that the default is IO, so that makes sense. • Switching to the
    CIO
    engine on the JVM target. ◦ No change, still stutters when loading data on Android • Running as profileable to debug further ◦ The problem disappears when I run a profileable build; scrolling is smooth while data loads, so it's unclear to me how to debug further or gather data on the issue You can repro by cloning https://github.com/PokeAPI/pokekotlin and running the demo app (the
    :demo-app
    module)
    c
    e
    e
    • 4
    • 14
  • h

    Harry

    06/11/2025, 11:01 PM
    Hey folks. What is the general consensus on whether property setters in Kotlin for a public API should throw exceptions when given invalid values, or if they should silently handle such cases (e.g., clamping values within a valid range)? For example, an image width property should not be negative.
    not kotlin but kotlin colored 1
    ➖ 1
    p
    j
    • 3
    • 2
  • t

    Tower Guidev2

    06/12/2025, 11:09 AM
    I have this variable declared in a library i cannot change
    Copy code
    abstract class WindowActivity : AppCompatActivity(), CoroutineScope {
    
        protected abstract var libraryVariable: LibraryType?
    is there any way i can change the LibraryType when overriding this variable? so that i have in my android app
    Copy code
    override var libraryVariable: ApplicationType? = null
    not kotlin but kotlin colored 1
    s
    u
    • 3
    • 3
  • n

    Nitesh Singh

    06/13/2025, 9:34 AM
    hey there, some time i am getting list of data from firestore and some time i am getting null list of data what is issue could you help me ?
    not kotlin but kotlin colored 5
    c
    • 2
    • 1
  • n

    Nitesh Singh

    06/13/2025, 11:08 AM
    okay could you give me link
    🧵 3
    c
    • 2
    • 1
  • a

    Arkadii Ivanov

    06/15/2025, 7:06 PM
    I wonder if the new
    NavigationEventDispatcher
    is a successor to
    OnBackPressedDispatcher
    ?
    not kotlin but kotlin colored 4
    c
    i
    • 3
    • 5
  • s

    Satyam Gondhale

    06/16/2025, 8:08 AM
    If I am using this block for grpc wire implementation by square, only either server or client code is generated. How can I get both server & client code at once
    Copy code
    wire {
        sourcePath {
            srcDir("src/commonMain/proto")
        }
    
        kotlin {
            rpcRole = "client"
            sourcePath("src/commonMain/proto")
        }
        kotlin {
            rpcRole = "server"
            rpcCallStyle = "blocking"
            sourcePath("src/commonMain/proto")
        }
    }
    not kotlin but kotlin colored 1
    c
    n
    • 3
    • 2
  • a

    Aman

    06/17/2025, 11:09 AM
    👋 Hello, team!
    o
    m
    a
    • 4
    • 5
  • a

    Asadullah Nadeem

    06/17/2025, 11:10 AM
    Hello
  • r

    Rohit Verma

    06/18/2025, 7:01 AM
    Hey everyone, I am having an issue about the Screen Recording Detection API introduced in Android 15. Is this the correct place to discuss that?
    not kotlin but kotlin colored 2
    c
    p
    n
    • 4
    • 10
  • i

    Ivan

    06/19/2025, 11:23 AM
    Hi everyone! I hope it is not against the rules to share SO links ... But I'm having trouble running some opencv-onnx classes in Android. I made a SO question with the details: https://stackoverflow.com/questions/79671982/how-to-use-onnx-based-trackers-in-opencv-android
    not kotlin but kotlin colored 2
    c
    • 2
    • 4
  • m

    muhamed khyamey

    06/25/2025, 2:09 PM
    👋 Hello, team!
  • s

    Satyam Gondhale

    06/26/2025, 7:39 AM
    Do we have any proper solution for this issue in Android
    android.app.RemoteServiceException$ForegroundServiceDidNotStartInTimeException: Context.startForegroundService() did not then call Service.startForeground(): ServiceRecord{b7b244e u0 com.myapp.client.test/com.myapp.client.app.services.HnavBootCompletedService}
    not kotlin but kotlin colored 4
    g
    c
    • 3
    • 3
  • d

    DutchPotSauce

    06/26/2025, 6:55 PM
    Hi has anyone, dealt with IR lowering issues specifically when updating to Kotlin to version 2.2?
    c
    • 2
    • 2