kevinskrei
12/14/2022, 4:18 PMThe code signature version is no longer supported.
when installing on a real iOS device? The app runs on the simulator fine and I've followed all of the steps here: https://kotlinlang.org/docs/multiplatform-mobile-understand-project-structure.html#ios-application
I'm just sharing a KMM module locally using embedAndSignAppleFrameworkForXcode
in the build phases and when I remove that build phase it will install fine on a real device. I see there is a way to share the code via cocoapods and using the path
to set it. But I'm trying to avoid using cocoapods on iOS.Sean Keane
12/14/2022, 4:42 PMiosArm64 {
binaries {
framework {
isStatic = true
transitiveExport = true
}
}
}
cocoapods {
summary = Metadata.IOS.summary
homepage = Metadata.IOS.homepage
version = Metadata.IOS.sdkVersion
ios.deploymentTarget = Metadata.IOS.deploymentTarget
framework {
baseName = Metadata.IOS.frameworkBaseName
isStatic = true
transitiveExport = true
}
pod("TensorFlowLiteTaskVision")
}
Basically when we use it we get this error in XCode Undefined symbol: _OBJC_CLASS_$_GMLImage
which is part of the Tensorflow pod...Patrik Andersson
12/14/2022, 8:05 PMDaniel
12/14/2022, 8:35 PMDaniel
12/14/2022, 8:37 PMfunc checkIfUser()
{
Task{
do{
try await self.repo.getUserProfile().watch() {items in//first method
self.myUser = items as! UserInfo
repo.insertFCMWhenLogin(token: myFCMToken!){error in//second method
}
saket
12/14/2022, 10:09 PMZeeshan Syed
12/15/2022, 9:36 AMcybr0ugh
12/15/2022, 2:37 PMStanislav Radchenko
12/15/2022, 3:18 PMErwin Pandawa5
12/15/2022, 3:24 PMTrey
12/15/2022, 4:48 PMmbonnin
12/15/2022, 10:54 PMynsok
12/16/2022, 9:05 AMProject already has a CocoaPods dependency with the name FirebaseCrashlytics
. Any idea how to solve this?
kotlin {
android()
ios()
cocoapods {
summary = "This module contains implementation of analytics and crashlytics"
ios.deploymentTarget = "15.0"
version = "1.10.2"
framework {
baseName = "monitoring"
pod("FirebaseCrashlytics")
// pod("FirebaseAnalytics")
}
}
}
Arkadii Ivanov
12/16/2022, 12:02 PMparcelize-darwin
compiler plugin, that I created a couple of years ago. And published the first version.
https://twitter.com/arkann1985/status/1603702344658685953
Basically it adds Parcelable and Parcelize support for all Darwin targets. Experimental. Together with expect/actual it makes it possible to use Parcelize in commonMain.Edgars Malahovskis
12/16/2022, 12:07 PMMarkRS
12/16/2022, 12:52 PMFernando
12/16/2022, 2:55 PMException in thread "main" java.lang.NoClassDefFoundError: io/ktor/client/engine/cio/CIO
, can you help me please?jean
12/16/2022, 9:31 PMgradle iosX64Test
and it works correctly thoughjessel
12/16/2022, 9:41 PMMPP
used as the shorthand for multiplatform?ian.shaun.thomas
12/16/2022, 9:42 PMDavide Giuseppe Farella
12/17/2022, 12:54 AMandroid()
variant, I cannot build because of
com.android.tools.r8.internal.Jc: Space characters in SimpleName ‘handles ConnectException’ are not allowed prior to DEX version 040This seems a bit awkward as Jvm Android modules can contain tests with backticks ( except instrumented tests ) Is there a solution/workaround? I could disable test
androidTest
if that would solve it ( how? ) as 99% of the code in the main source setQyhyzard
12/17/2022, 4:59 AMKshitij Patil
12/17/2022, 1:13 PMRussell Stewart
12/17/2022, 9:30 PMWaqas Tahir
12/18/2022, 9:51 AMmartmists
12/18/2022, 1:39 PMCannot locate tasks that match ':ac-frontend:compileJava' as task 'compileJava' is ambiguous in project ':ac-frontend'. Candidates are: 'compileDebugAndroidTestJavaWithJavac', 'compileDebugJavaWithJavac', 'compileDebugUnitTestJavaWithJavac', 'compileReleaseJavaWithJavac', 'compileReleaseUnitTestJavaWithJavac'.
If I add withJava
to my kotlin { jvm { ... }}
configuration, it complains it conflicts with the Android plugin. What do I do in this situation?spierce7
12/18/2022, 6:31 PMDaniel
12/18/2022, 7:30 PMsuspend fun doLogout(token: String) {
val userId = appService.currentUser?.id
realm.write {
var user = query<UserInfo>("_id = $0", userId).first().find()
if (user != null) {
val productIndex =
user.FCMToken.withIndex().findLast { it.value == token }!!.index
user = findLatest(user)!!.also {
it.FCMToken.removeAt(productIndex)
}
copyToRealm(user)
appService.currentUser?.logOut() // Suspension functions can be called only within coroutine body
}
}
}
Is there anyway to fix this without changing much code?
I need to do first the db operation then logOut()Ksenia Shneyveys
12/19/2022, 10:44 AMHasan Nagizade
12/19/2022, 5:02 PMHasan Nagizade
12/19/2022, 5:02 PMLandry Norris
12/19/2022, 5:03 PMHasan Nagizade
12/19/2022, 5:03 PMCorey
12/19/2022, 5:24 PMHasan Nagizade
12/19/2022, 5:30 PMCorey
12/19/2022, 5:33 PMexpect
and actual
Since it is only Android for now, you can leave the iOS part empty. I'm doing the same, although I don't have a common VM, I've started with iOS only. Android is fully empty. 😄 😄Hasan Nagizade
12/19/2022, 5:39 PMSam
12/19/2022, 8:40 PMdarkmoon_uk
12/20/2022, 12:49 AMWhat is the official recommended way to keep viewmodels?There's no official recommendation on this, and nor should there be: Your UI architecture is Application specific and this is out-of-scope of Kotlin Multiplatform. KMP is there to support code-sharing, whichever UI architecture you adopt. Generally though, if you're not attempting to share any of your presentation logic at all, then IMO you're missing out on the full benefit of Kotlin Multiplatform. Most of the time (KMM scenario) the View layer requirements are similar enough that it's straightforward to achieve a common (MVVM) ViewModel. Even where the UI differs greatly - for example, where in one of my projects I have a CLI client - you can still use KMP's 'hierarchical source-sets' to achieve e.g.
graphicalMain
that provides common VM sources for `ios`/`android` graphical targets, while the cli
presentation layer can be separate and different.