Stephen Gazzard
04/29/2021, 7:59 PMException doesn't match @Throws-specified class list and thus isn't propagated from Kotlin to Objective-C/Swift as NSError.
It is considered unexpected and unhandled instead. Program will be terminated.
Uncaught Kotlin exception: com.apollographql.apollo.ApolloNetworkException: Failed to execute GraphQL http network request
Seems a built in part of the KMM framework is if your Kotlin function doesn’t mark @Throws() with the exception, KMM crashes your app. There’s no compile time safety enforcing that only exceptions annotated in @Throws, so it is possible that an exception is missed that later ends up crashing your iOS application. This is undesired behaviour, as if we miss documenting an exception, it can crash in the wild. In iOS, we typically just show an error message when an unexpected error arises. Is there a way to ensure that Kotlin never crashes us in this case?Jeff Tycz
04/30/2021, 1:02 AMtoSortedMap
seems not to be available in the common module only the JVM. What is the way to sort a hashmap in the common module?Rita Okonkwo
04/30/2021, 7:45 AMAlex Anisimov
04/30/2021, 4:22 PMrocketraman
04/30/2021, 9:06 PMmapping.txt
files -- one in the shared
build, and one in the Android app build. However, the Play store only accepts one file. Does the Android one contain all the necessary information from shared
?Saiedmomen
04/30/2021, 9:11 PMKD
04/30/2021, 10:07 PMChristian Gaisl
05/02/2021, 7:03 PM//Does not work with SwiftUI preview
class Greeting1(
var testString: String
) {
fun greeting(): String {
return "Hello, ${Platform().platform}!"
}
}
//Works with SwiftUI preview
class Greeting2(
testString: String
) {
fun greeting(): String {
return "Hello, ${Platform().platform}!"
}
}
An instance of this class being part of the view, even if none of its members are actually displayed, crashes the preview. It works fine on the simulator though.
This does not happen in the template project when using the Xcode build phases framework approach, the one with the packForXcode task.
Does anyone have any idea what could cause this?José González Gómez
05/03/2021, 11:35 AMsrc/commonTest/resources
but they don't seem to get copied to the output directory when running Android tests. Putting them under src/androidTest/resources
did the trick for Android tests, but I don't want to have two copies of these files, as they are common for both Android and iOS tests.jmfayard
05/03/2021, 1:00 PMjava.util.File
on the JVM
and POSIX calls on Kotlin native fopen
, fclose
, acccess
, ...xxfast
05/04/2021, 1:15 AMFabio Santo
05/04/2021, 6:38 AMrb90
05/04/2021, 10:33 AMJozef Matus
05/04/2021, 12:53 PMsuspendCoroutine
from another thread? Im getting CoroutinesInternalError: Fatal exception in coroutines machinery for DispatchedContinuation
Yusuf
05/04/2021, 2:12 PMJosé González Gómez
05/04/2021, 2:22 PMandroidTest
source set?? I'm getting this:
Warning:project ':xxx': Unable to build Kotlin project configuration
Details: org.gradle.api.InvalidUserDataException: Source directory '/Users/xxx/Documents/projects/xxx/src/androidTest/resources/provider-metadata.json' is not a directory.
when reloading the Gradle project in Android Studio. I've tried putting the file both in the root androidTest/resources
directory and in a nested folder under that directory.
If I do the following it works properly:
1. Remove any files under androidTest/resources
2. Reload the Gradle project in Android Studio
3. Move/copy files to androidTest/resources
4. Run tests to my heart's content without any problem using existing Android Studio's Run/Debug configuration
I can also run ./gradlew build
or ./gradlew test
without any problem with files located under androidTest/resources
... I've even tried to re-create the Android Studio project deleting the .idea
folder and re-opening the project... what am I doing wrong????Jeremias Nunez
05/04/2021, 2:55 PMVitor Prado
05/04/2021, 3:06 PMJosh
05/04/2021, 5:18 PMchi
05/04/2021, 8:02 PMVitor Prado
05/04/2021, 9:17 PMdarkmoon_uk
05/05/2021, 2:17 AMMikhail Buzuverov
05/05/2021, 4:59 AMMichal Klimczak
05/05/2021, 6:23 AMplatform.*
etc. I guess the problem is with it not properly collecting sources, but how do I fix it?Berkan
05/05/2021, 2:55 PMjmfayard
05/05/2021, 7:01 PMsushma nayak
05/05/2021, 8:22 PMkotlin.native.concurrent.InvalidMutabilityException: mutation attempt of frozen
exception.
Dependencies info -
kotlin = "1.4.30"
coroutines = "1.4.2-native-mt"
serialization = "1.0.1"
ktor = "1.4.2"
This is what I’m doing -
class Manager {
var user: User
init(){
GlobalScope.async(context = Dispatchers.Default) {
val result = callToSuspendFunction
user = result //ERROR ON THIS LINE
}
}
How to achieve something like this?Napa Ram
05/06/2021, 5:35 AMAndyeshiet
05/06/2021, 8:35 AMpackForXcode
with the cocoapods
approach, everything runs fine on the android, but i get an error while trying to build for ios. Error shown ☝️Napa Ram
05/06/2021, 9:58 AM