https://kotlinlang.org logo
Join Slack
Powered by
# touchlab-tools
  • b

    Bradleycorn

    05/14/2025, 8:57 PM
    Hi all. I am updating to the latest KmmBridge (from 0.5.5), and I'm getting the dreaded "*Task 'kmmBridgePublish' not found in root project"* error when running a build via CI (Github Actions). First, yes, I am passing the
    ENABLE_PUBLISHING=true
    property when running the kmmBridgePublish task. Hoping someone can point me in the right direction .... More details in the 🧵
    k
    • 2
    • 9
  • b

    Bradleycorn

    05/15/2025, 8:44 PM
    New kmmBridge question ... Recent versions (1.2.1) publish the xcframework artifact to the github release and reference the URL for that artifact in the Package.swift file that gets produced. In my case, I also need to support cocoapods (bleh ... at least for the time being). The cocoapods quickstart looks like it is configured to still use maven repo (github packages) for the artifact. Is there a way to get it to use the same artifact that spm uses (the file uploaded to the github release)? I was hoping that it would "just work" by using the
    gitHubReleaseArtifacts()
    configuration, but alas it doesn't seem to. I have the proper deploy keys, netrc entries, etc setup. But my (CI) build fails when validating the produced podspec. I get:
    Copy code
    - ERROR | [iOS] unknown: Encountered an unknown error ([!] /usr/bin/curl -f -L -o /var/folders/w5/_8wgjw3j5cg6mgrth3s2kg9m0000gn/T/d20250515-12410-9mp3pi/file.zip <https://api.github.com/repos/myorg/myrepo/releases/assets/255030196.zip> --create-dirs --netrc-optional --retry 2 -A 'CocoaPods/1.16.2 cocoapods-downloader/2.1' -H Accept: application/octet-stream
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
      0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
      0   280    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
    curl: (56) The requested URL returned error: 403
    ) during validation.
    Perhaps there's something else I need to do with the configuration or ci build workflow?
    • 1
    • 1
  • b

    Bradleycorn

    05/16/2025, 5:48 PM
    Following up on my post yesterday about kmmbridge and cocoapods ... Seems like it's a permissions issue when it tries to validate the podspec (and thus pull down the framework from the supplied url). My repo is private, but I have setup an ssh key and a netrc file (the same as what I have been using for kmmbridge 0.5.5), so it seems like it should work, but apparently not. Anyone know of any other authentications I need to provide?
  • k

    kpgalligan

    05/16/2025, 6:38 PM
    There was a bug with using release builds with cocoapods, but AFAIK, that should be fixed and published. Cocoapods is a huge PITA for CI, and not that many people are using it now, so the KMMBridge config for it rarely gets run or troubleshot. Cocoapods specifically won't publish unless it can build successfully, which means the 15 things you need to do need to be done exactly correct. The only reasonable way to debug that is to try to publish from you local machine with that release URL, then if that works, try to debug why CI is failing.
    b
    • 2
    • 4
  • l

    Leo Yamamoto

    05/20/2025, 5:25 PM
    Hi there! 👋 When might there be a new release of Kermit that includes this recently-merged PR #439?
  • n

    Nikolay Kasyanov

    05/27/2025, 2:41 PM
    Hello folks, I have a question that is related to Skie. With Skie adding Swift code to KMP frameworks, this becomes relevant to reduce their final size. I’m curious if anyone has done it already for their framework. I tried to slap something together but the issue I’m facing is this: if I do the stripping after my framework is assembled, this modifies the output of the assembly task, meaning it will be always re-run in the next build, and then stripped again, the cycle continues. What could be a way around that? A broader question: would this make a good configuration option for Skie itself?
    d
    t
    • 3
    • 8
  • c

    Christopher Mederos

    05/29/2025, 1:29 AM
    given the latest SKIE release, will there be a release for compose-swift-bridge supporting Kotlin 2.1.20 as well? thanks!
    ☝️ 1
  • m

    Mark

    06/01/2025, 11:34 AM
    I’m in the process of migrating my Android app to KMP, and am about to tackle the sqlcipher/sqldelight part. I noticed this article, but also that it’s about 5 years old. Is it still the way to go, or have there been relevant developments since? https://touchlab.co/multiplatform-encryption-with-sqldelight-and-sqlcipher
    k
    • 2
    • 1
  • b

    Bradleycorn

    06/10/2025, 3:49 PM
    I'm having some trouble with KmmBridge. Specifically, the
    touchlab/ga-update-release-tag
    github action doesn't seem to be working right ... The action runs (successfully), but it doesn't seem to do anything. When I check the tag that gets created in my repo, there is no extra commit, and there is no Package.swift file. However, when I check the github release, the xcframework binary has bee uploaded. That part from the build steps seems to be working. It's just that the update release tag action doesn't seem to be working or doing anything. not sure what I'm doing wrong, or where to start debugging.
    • 1
    • 1
  • t

    Trey

    06/10/2025, 8:28 PM
    I'm using Kotlin Multiplatform resources and SKIE. Is there a way to grab a resource string from Swift code easily? This is just for a default string in an extension on iOS.
  • d

    David

    06/12/2025, 10:46 AM
    I added SKIE to my KMM lib, the diff looks like this: Now I'm getting in Xcode the error "Could not build Objective-c module..." Any idea what the issue might be?
    f
    • 2
    • 1
  • c

    christian.steffensen

    06/19/2025, 11:10 AM
    EDIT: resolved, nevermind 🙂 Posting this here, as it seems to be related to suspending functions and enums, apologies if it’s actually more of a general multiplatform question 🙂 Just looking to hear if anyone has experienced something similar We’re having a weird issue where iOS is suddenly not able to see suspending functions and enums. It has worked perfectly fine and just “randomly” broke, even though we hadn’t changed anything major in the latest version of our shared library. It works when building locally with We get errors like
    Value of type X has no member Y
    where X is a class and Y is a suspending function We also get the error:
    No exact matches in global call to onEnum
    The only thing we have changed recently is updated to Kotlin 2.1.20, where we got a
    Can't find env_blacklist file
    error, which was at first fixed by calling
    ./gradlew commonizeNativeDistribution
    before building - that fixed the build and the following released worked just fine. But, now we just made another release and it no longer works on iOS, with the issues mentioned above. On suggestion from KT-72068 we have tried adding
    kotlin.native.toolchain.enabled=false
    but that made no difference Skie 0.10.2 Kotlin 2.1.20 Gradle 8.11.1 The library is built using assembleFramework and publishing it manually to github package registry
    • 1
    • 1
  • d

    Daniel Žůrek

    06/20/2025, 1:53 PM
    Hey all 👋 I have a question related to
    Gitportal
    . Library files are added to git, running
    gitportal setup library ...
    command, even though the library folder is in
    .gitignore
    . Resulting in:
    Copy code
    The following paths are ignored by one of your .gitignore files:
    library
    Is this an intentional way of force versioning in android/ios repo? We want to use gitportal for our shared code but we'd like to avoid having the same code mixing in PRs etc.
    👀 1
    k
    • 2
    • 1
  • a

    aoriani

    07/02/2025, 2:06 AM
    I created a small PR to add wasm support for kermit-koin https://github.com/touchlab/Kermit/pull/447. Thanks cc: @kpgalligan @Sam Hill @Kevin S
    👍 1
    k
    • 2
    • 1
  • j

    Johan Reitan

    07/03/2025, 3:24 PM
    After updating to Kotlin 2.2.0 the dreaded linker issue with kermit-crashlytics returned:
    Copy code
    dyld[42183]: symbol not found in flat namespace '_FIRCLSExceptionRecordNSException'
    This only happens when running tests. I have disabled the native cache, applied the
    crashkios
    plugin and also added the linker options manually to no avail:
    Copy code
    compilerOptions.freeCompilerArgs.addAll(
        "-linker-options",
        "-U _FIRCLSExceptionRecordNSException ",
    )
    What changed?
  • s

    Stylianos Gakis

    07/07/2025, 8:14 AM
    A sanity check, using SKIE, if I am publishing a XCFramework using an "umbrella" module which wraps and also publishes other modules, do I need SKIE applied on: • just on the modules that contain the source code • only on the umbrella module • both
    f
    • 2
    • 2
  • j

    jessewilson

    07/08/2025, 7:37 PM
    I’m setting up Xcode Kotlin and my breakpoints aren’t working. Any tips?
    k
    • 2
    • 8
  • a

    Abhishek Agarwal

    07/12/2025, 9:37 PM
    Hey All, I’m hitting a weird SPM issue in our Prod-scheme Simulator build: Env: macOS 26, Xcode sim iOS 18.5, skie 0.10.4, kmmbridge 1.0.0, xcode 16.4 Setup:
    ./gradlew spmDevBuild
    → debug XCFramework with arm64-device, arm64-sim & x86_64-sim I am able to run the debug version of my app with the generated kMP spm package in any simulator and real device but the release version of the app is running only in real device , when trying to run it in simulator the build fails showing error like
    Copy code
    Cannot find type 'SkieSwiftFlow' in the scope   
    Cannot find files from my Kotlin code....
    I use umbrella module technique to build KMPModules , this is how it is configured
    Copy code
    listOf(
        iosArm64(),
        iosSimulatorArm64(),
        iosX64()
    ).forEach {
        it.binaries.framework {
            export(project(":kmm-analytics"))
            export(project(":kmm-util")) 
            //...other modules 
            export(libs.resources)
            export(libs.androidx.lifecycle.viewmodel)
            isStatic = true
            baseName = "KMMShared"
        }
    }
    t
    f
    b
    • 4
    • 23
  • c

    Christopher Mederos

    07/14/2025, 1:11 AM
    Has anyone managed to get compose-swift-bridge working with cmp 1.8? I tried bumping my kotlin, skie, ksp versions... but all the ksp configurations are no longer being picked up in my gradle build. Any thoughts? ( these configs from the docs aren't picking up the tasks correctly anymore)
    Copy code
    // Adds the required targetName for the KSP plugin
    tasks.withType<com.google.devtools.ksp.gradle.KspTaskNative>().configureEach {
        options.add(SubpluginOption("apoption", "compose-swift-bridge.targetName=$target"))
    }
    
    // support for generating ksp code in commonCode
    // see <https://github.com/google/ksp/issues/567>
    tasks.withType<org.jetbrains.kotlin.gradle.tasks.KotlinCompilationTask<*>>().configureEach {
        if (name != "kspCommonMainKotlinMetadata") {
            dependsOn("kspCommonMainKotlinMetadata")
        }
    }
    Missing subplugin option -
    Copy code
    [ksp] java.lang.IllegalArgumentException: Missing compose-swift-bridge.targetName, see docs
    Missing task depends on -
    Copy code
    Reason: Task ':composeApp:kspKotlinIosSimulatorArm64' uses this output of task ':composeApp:kspCommonMainKotlinMetadata' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.
    • 1
    • 1
  • j

    jessewilson

    07/14/2025, 2:16 PM
    I just got this scary-looking compile fail:
    Copy code
    > Task :zipline:iosX64Quickjs FAILED
    In file included from /Volumes/Development/zipline/zipline/native/quickjs/quickjs.c:34:
    /Applications/Xcode-16.4.0.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator18.5.sdk/usr/include/math.h:619:27: error: _Float16 is not supported on this target
    extern _Float16 __fabsf16(_Float16) __API_AVAILABLE(macos(15.0), ios(18.0), watchos(11.0), tvos(18.0));
                              ^
    I tracked it down thanks to this bug. The fix was straightforward, once I figured out where to put it:
    Copy code
    cklib {
      config.kotlinVersion = libs.versions.kotlin.get()
      create("quickjs") {
        language = C
        srcDirs = project.files(file("native/quickjs"), file("native/common"))
        compilerArgs.addAll(
          listOf(
            ...
            "-D_Float16=short", // KT-69094
          )
        )
      }
    }
  • n

    Nikky

    07/20/2025, 6:26 PM
    hi, i am trying to use sqliter with a mingwX64 target
    Copy code
    > Task :linkDebugExecutableMingwX64 FAILED
    e: C:\Users\nikky\.konan\dependencies\llvm-16.0.0-x86_64-windows-essentials-56/bin/clang++ invocation reported errors
    
    The C:\Users\nikky\.konan\dependencies\llvm-16.0.0-x86_64-windows-essentials-56/bin/clang++ command returned non-zero exit code: 1.
    output:
    lld: error: unable to find library -lsqlite3
    clang++: error: linker command failed with exit code 1 (use -v to see invocation)
    i saw that the github CI for this project sets up msys2 with a few packages.. and adds msys2 to the path so i installed that also tried running it from within mysys2 is there any sample project that uses ideally sqldelight and sqliter on a windows target ? tried adding the same linkeropts like so
    Copy code
    compilations.forEach { kotlinNativeCompilation -> kotlinNativeCompilation.kotlinOptions.freeCompilerArgs += listOf("-linker-options", "-lsqlite3 -Lc:\\msys64\\mingw64\\lib") }
    this produces a different set of errors.. mainly a bunch of undefined symbol stuff
    k
    • 2
    • 1
  • j

    John O'Reilly

    08/02/2025, 7:49 AM
    Is there a pre-release version of SKIE that I can use alongside Kotlin
    2.2.20-Beta2
    ?
  • b

    Bradleycorn

    08/05/2025, 3:32 PM
    Hey gang ... We are finally getting our ios app off of cocoapods ( 🎉 ). We're using KmmBridge and have it setup with binaries and SPM. This works fine. Our next step is to setup Kotlin Debugging in Xcode. I've done this a little bit before in a demo project, so I'm familiar with how it works, etc... Our devs are setup to use the local dev flow so that they can build the app, and have it use their local copy of the kmp project (which is based on a feature branch of the feature they are working on). My question is, how do you all handle doing CI builds of in-flight features (i.e. builds in between versioned releases). We basically need something similar to the "local dev flow", but for CI (specifically, github actions). When a PR is merged into a feature branch, we kick off a build of the feature branch in github actions to produce a build of the app that our QA team can use for testing. I'm curious if anyone has come up with a good way to facilitate these incremental CI builds? Right now, we just publish a new version of the kmp library every time. But that's not really sustainable. I'm wondering if there's a better way?
    s
    • 2
    • 1
  • m

    MarkRS

    08/06/2025, 3:20 PM
    The Kermit web page says "Disable local logging for production, or even strip log statements altogether with a compiler plugin" but I can't find any reference to these in the documents. Where should I look?
    k
    • 2
    • 4
  • b

    Bradleycorn

    08/07/2025, 1:29 PM
    Hi all, Question about the "SPM Local Dev Flow" for KmmBridge. I set it up and everything works pretty good. When I'm working in that flow, ifI make some edits to the kotlin code, I presume I'll need to run the
    spmDevBuld
    again to produce a new framework with the updated code changes ... right?
    k
    • 2
    • 1
  • b

    Bradleycorn

    08/15/2025, 3:10 PM
    Hi Everyone. Several people have run into an issue in Android Studio with KMP projects when using the TouchLab Xcode Kotlin plugin. The issue is defined here: https://youtrack.jetbrains.com/issue/KMT-1299/After-upgrading-to-Narwhal-Project-JDK-is-not-defined A few details: When you have an "integrated" project, and you use the Xcode Kotlin plugin to debug kotlin code in Xcode, you will run into this issue when you open the project in Android Studio Narwhal (and have the Kotlin Multiplatform Plugin enabled in Android Studio). As stated in the linked issue, when you add a reference to the Kotlin source files in your Xcode project (so that you can set breakpoints and debug), it causes some kind of issue, and back over in Android Studio everything goes haywire. If you remove the references to the Kotlin source files from the Xcode project, the project immediately starts working again in Android Studio. Anyway, I don't know/think this is an issue with the Touchlab Xcode plugin (it seems to be an issue with the IntelliJ KMP Plugin for Android Studio). But I wanted to post it here in case anyone else runs into it. h/t to @Brandon Smith for figuring out the issue!
    k
    • 2
    • 3
  • a

    audax

    08/21/2025, 7:38 AM
    We are building a multiplatform shared module which is providing ViewModels, but not Views. How do I best provide a Coroutine scope and all the lifecycle stuff on iOS? Ideally I want to use the KMP-ViewModel directly as state and for callbacks. I need to pass some arguments into the constructor of the ViewModel.
    f
    d
    • 3
    • 17
  • j

    Jacob Kwitkoski

    08/27/2025, 6:30 PM
    We're looking at using GitPortal to help manage our KMP explorations, but there's a couple things holding us back: 1. Lack of support for self-managed/self-hosted (e.g. GHE) https://github.com/touchlab/GitPortalCli/issues/1 2. Inability to turn off Sentry: https://github.com/touchlab/GitPortalCli/blob/main/cli-build/src/commonMain/kotlin/MainCli.kt#L10-L21 For
    2.
    should I log a new issue on GitHub for that?
  • t

    touchlab_justin

    09/08/2025, 8:38 PM
    Last week, SKIE hit 1000 github ⭐🤩 (we hit 1000 users a long time ago) Perfect timing, because Sep 5 was SKIE’s 2 year anniversary of launching as open source 🎊 🎂 Thank you to everyone using SKIE, offering feedback, and sharing your experiences in blog posts 🙏 If you are using SKIE in production, please take a moment to post to https://github.com/touchlab/SKIE/discussions/154 🙋 if you can’t share, please send another ⭐
    🚀 10
  • j

    John O'Reilly

    09/12/2025, 4:04 PM
    When is it hoped (roughly) to have version of SKIE that works with Kotlin 2.2.20?
    ⏳ 7
    plus1 4
    d
    • 2
    • 1