Hi everyone. I encountered an issue when using the...
# kotlin-toolchain
a
Hi everyone. I encountered an issue when using the Kotlin Toolchain to run a JVM console application. Whenever I have an input prompt (readln), the toolchain task progress bar blocks the UI so I can't see the text I'm typing till I press enter. I tried to see if there's an option to hide the progress bar while using the
kotlin run
command but I couldn't find any. Any solution or workaround for this?
f
Hi, yes, it's a known problem, you can track youtrack.jetbrains.com/issue/KTC-5423
a
Thanks @Fedor Ihnatkevich. The last comment was two months ago though πŸ₯²
p
I teach programming concepts using Kotlin, and this problem completely prevents the use of Kotlin ToolChain. I'll have to continue using Gradle. πŸ˜₯
πŸ‘πŸΎ 1
a
Same here @Pedro Pereira
f
The issue with the progress bar and the status widget interfering with the interactive process was solved, so the latest
-dev
already has the fix. There is still KTC-5596, we'll try to solve that soon as well
p
This simple program doesn't work yet:
Copy code
fun main() {
    print("Your name ? ") // not a println
    val name = readln()
    println("Hello $name")
}
The first output only appears after the input has been performed.
f
I see, that's because of the buffering that we do. We'll solve it as part of the KTC-5596, thanks for reporting.
j
Hi folks! KTC-5596 is now fixed in
0.12.0-dev-4208
. Thanks for your patience! Now both input and output are properly inherited from the CLI process, and you'll get proper interactivity without progress bar mess πŸ™‚
πŸš€ 1
πŸ‘ 1
You can already try it out using
kotlin update --dev
in your project, or wait until the next release
πŸ‘πŸΎ 1
πŸ‘ 1
a
Thanks for the feedback @joffrey. Do you have an ETA for the next release?
j
I don't have a very precise date, but it should happen before the end of August
πŸ‘πŸΎ 1
πŸ‘ 1
a
Alright, that's fine. I'll check out the dev release version.