https://kotlinlang.org
Join Slack
Hi folks. I want to upload a huge multipart file to my server via Ktor Client. Any ideas or tips? Th...
m

Mikhail

over 3 years ago
Hi folks. I want to upload a huge multipart file to my server via Ktor Client. Any ideas or tips? The file is considered to be larger than 2GB.
m
f
+3
  • 5
  • 12
  • 1711
Hi, debugging the iOS platform on KMP is proving to be a bit complicated. I am not sure if I am doin...
j

Jose Garcia

about 3 years ago
Hi, debugging the iOS platform on KMP is proving to be a bit complicated. I am not sure if I am doing something wrong, but is it not possible to inspect variables or evaluate expressions using the intelliJ debugger? I can set the breakpoints fine but when it comes to seeing the snapshot of my objects I don’t get any output, just errors.
j
k
+3
  • 5
  • 63
  • 1710
Can compose infer stability of a `sealed` class ? ```sealed class MyClass { object A : MyClass()...
r

ritesh

over 3 years ago
Can compose infer stability of a
sealed
class ?
sealed class MyClass {
  object A :  MyClass()
  data class SomeClass(val value:String): MyClass()
}
r
g
+2
  • 4
  • 28
  • 1709
How do we configure serialization now with Ktor 2.0 on an Android client? This example for previous...
n

Nathan Kleinschmidt

over 3 years ago
How do we configure serialization now with Ktor 2.0 on an Android client? This example for previous versions is deprecated and no longer works:
client = HttpClient(Android) {
    install(JsonFeature) {
      serializer = KotlinxSerializer()
    }
}
The migration guide says to use the content negotiation plugin, but there are no examples of how to do this on Android that I can see.
n
d
+3
  • 5
  • 11
  • 1702
Hello everyone. I am trying to change a variable in a singleton and the IDE displayed me the followi...
f

Francis Mariano

over 3 years ago
Hello everyone. I am trying to change a variable in a singleton and the IDE displayed me the following message:
With old Native GC, variable in singleton without @ThreadLocal can't be changed after initialization
. Are there a new Native GC ????
f
m
k
  • 3
  • 3
  • 1694
Hey ! I want to ask people around if `runCatching` is in use in any of your Kotlin (or Android) pro...
n

Nino

over 2 years ago
Hey ! I want to ask people around if
runCatching
is in use in any of your Kotlin (or Android) projects ? I feel my team is abusing it and I'm trying to understand if there's any "pros" about using it in any coroutine-based codebase. My team just adopted this convention and I'm at loss of words. (Examples in thread for anyone interested)
n
j
+6
  • 8
  • 107
  • 1684
Hi, how can I convert a Swift `NSData` to Kotlin `ByteArray`? Background: I’m working on a Kmp libra...
b

Bao Le Duc

over 2 years ago
Hi, how can I convert a Swift
NSData
to Kotlin
ByteArray
? Background: I’m working on a Kmp library where we need to use OS’s crypto API to encrypt data. So, in Kmp library we define an Interface
interface MessagePackHelper {
    fun serialize(payload: String): ByteArray
}
from iOS, we need to implement this interface and set back to the Kmp library. So in Swift, we need to implement below method:
func serialize(payload: String) -> KotlinByteArray {
        // let encyrpted = encrypt(payload) // result is NSData obect
        // todo - would like to convert NSData -> KotlinByteArray
    }
b
e
  • 2
  • 5
  • 1675
Hi, how do I pass environment variables in a Gradle Configuration that runs the `:run` task to the K...
a

Ayfri

over 2 years ago
Hi, how do I pass environment variables in a Gradle Configuration that runs the
:run
task to the Kotlin project of this task ?
a
j
+2
  • 4
  • 21
  • 1673
Anyone have experience with using Mapbox with Kotlin Multiplatform?
j

james

over 4 years ago
Anyone have experience with using Mapbox with Kotlin Multiplatform?
j
d
+2
  • 4
  • 7
  • 1668
hi there, I'm trying to run an UI test in shared/commonTest and facing the following NPE. This tests...
k

Kathrin

over 1 year ago
hi there, I'm trying to run an UI test in shared/commonTest and facing the following NPE. This tests works fine when I run it in androidInstrumentedTest. Any ideas?
java.lang.NullPointerException: Cannot invoke "String.toLowerCase(java.util.Locale)" because "android.os.Build.FINGERPRINT" is null
	at androidx.compose.ui.test.AndroidComposeUiTestEnvironment.runTest(ComposeUiTest.android.kt:314)
	at androidx.compose.ui.test.ComposeUiTest_androidKt.runAndroidComposeUiTest(ComposeUiTest.android.kt:114)
	at androidx.compose.ui.test.ComposeUiTest_androidKt.runComposeUiTest(ComposeUiTest.android.kt:61)
	at androidx.compose.ui.test.ComposeUiTest_androidKt.runComposeUiTest$default(ComposeUiTest.android.kt:60)
k
a
+3
  • 5
  • 17
  • 1663
Previous151617Next

kotlinlang

A modern programming language that makes developers happier.

Powered by