https://kotlinlang.org
Join Slack
Hi, I'm getting `No tests found for given includes` error when I try to run my tests. As far as I co...
o

Osman Saral

over 4 years ago
Hi, I'm getting
No tests found for given includes
error when I try to run my tests. As far as I could find, solutions proposed for this error are: 1. Adding
useJUnitPlatform()
to build.gradle. I'm using junit4 and this doesn't work 2. import
org.junit.jupiter.api.Test
instead of
import org.junit.Test
. Same as above 3. change setting Gradle -> Run Tests Using' from 'Gradle (default)' to 'IntelliJ IDEA'. This setting is not there on Android Studio Arctic Fox or Bumblebee I've tried to copy all the test related codes from KaMPKit and using exactly the same dependency versions as this branch. Same tests run on KaMPKit project but not on my project. Did anyone get this error before? What am I doing wrong?
o
  • 1
  • 1
  • 335
We are trying to update our app to use Kotlin 2.0. When building the release version, we received a ...
a

aliftc12

over 1 year ago
We are trying to update our app to use Kotlin 2.0. When building the release version, we received a warning about R8: "An error occurred when parsing Kotlin metadata." We checked https://developer.android.com/build/kotlin-support and found that there is no support for this version of Kotlin yet. Should we wait for a new R8 version that supports Kotlin 2.0?
a
l
  • 2
  • 5
  • 334
How do I use FontResource in CMP 1.6.0 beta02? I have composeResources/font/myfont.ttf in shared fol...
j

Joel Denke

almost 2 years ago
How do I use FontResource in CMP 1.6.0 beta02? I have composeResources/font/myfont.ttf in shared folder. Trying to do like this from another module:
Font(resource = FontResource("myfont"), weight = FontWeight.Normal, style = FontStyle.Normal)
Should the path or id be different somehow?
j
m
+2
  • 4
  • 28
  • 334
Hello, is there a coroutine-friendly alternative to `ConcurrentHashMap`? The idea is that an update ...
d

domfox

about 2 years ago
Hello, is there a coroutine-friendly alternative to
ConcurrentHashMap
? The idea is that an update to the map via
compute
might be a suspending function, and the map should lock out the hash bucket being updated until that function has completed. I have this naive version which locks out the entire map:
class CoroutineMap<K : Any, V : Any> {

    private val data: MutableMap<K, V> = mutableMapOf()
    private val dataLock = Mutex()
    
    suspend fun compute(key: K, update: suspend (V?) -> V?): V? = dataLock.withLock { 
        val updated = update(data[key])
        if (updated == null) data.remove(key) else data[key] = updated
        updated
    }
}
but a version with per-bucket mutexes would be better, I believe?
d
b
k
  • 3
  • 6
  • 334
Is there a WASM API that one can use to replace DataStore to persist key-value pairs?
e

Emre

over 2 years ago
Is there a WASM API that one can use to replace DataStore to persist key-value pairs?
e
b
t
  • 3
  • 4
  • 334
I am currently getting ```Module parse failed: The top-level-await experiment is not enabled (set ex...
a

andylamax

over 2 years ago
I am currently getting
Module parse failed: The top-level-await experiment is not enabled (set experiments.topLevelAwait: true to enabled it)
You may need an appropriate loader to handle this file type, currently no loaders are configured to process this file. See <https://webpack.js.org/concepts#loaders>
Error: The top-level-await experiment is not enabled (set experiments.topLevelAwait: true to enabled it)
When I am compiling a multiplatform library with wasm targets I have added this to my
webpack.config.d
var experiments = config.experiments || {}
experiments.topLevelAwait = true
But still the problem persists
a
  • 1
  • 1
  • 334
How do I make a Composable transparent for clicks? I want my Composable to "disappear" both visually...
a

alaershov

over 2 years ago
How do I make a Composable transparent for clicks? I want my Composable to "disappear" both visually and for click events, so that the user is able to click some content below my Composable. But my Composable should still be counted in size calculations, kinda like INVISIBLE in View system. Any ideas how to make clicks pass though my Composable?
a
j
a
  • 3
  • 7
  • 334
Playing with IntelliJ's new UI - any one know if it's possible to bring back some buttons at the top...
b

bod

almost 3 years ago
Playing with IntelliJ's new UI - any one know if it's possible to bring back some buttons at the top of the screen? For instance I use "Back" a lot and miss it (I should totally use the keyboard instead but old habits...)
b
t
+2
  • 4
  • 12
  • 334
Is this not fixed? <https://youtrack.jetbrains.com/issue/KTIJ-18630> Can't access `reservation` para...
s

Sourabh Rawat

over 3 years ago
Is this not fixed? https://youtrack.jetbrains.com/issue/KTIJ-18630 Can't access
reservation
parameter in debugger at the debug point at line 26. It says
This variable is inaccessible because it isn't used after the last suspension point
Using coroutines
1.6.0
s
e
  • 2
  • 5
  • 334
Hi guys, seems gradle is not recognizing docker. I’m using runDocker gradle task but I get: `Executi...
a

Arnau Miro

over 1 year ago
Hi guys, seems gradle is not recognizing docker. I’m using runDocker gradle task but I get:
Execution failed for task ':jibDockerBuild'.
> com.google.cloud.tools.jib.plugins.common.BuildStepsExecutionException: Cannot run program "docker": error=2, No such file or directory
buildFatJar and buildImage are working well. Thanks in advance!!
a
a
  • 2
  • 8
  • 333
Previous207208209Next

kotlinlang

A modern programming language that makes developers happier.

Powered by