Daniele Segato
12/11/2020, 5:14 PMjava.lang.NoSuchMethodError: No direct method <init>(Lkotlin/coroutines/CoroutineContext;I)V in class Lkotlinx/coroutines/flow/internal/ChannelFlow; or its super classes (declaration of 'kotlinx.coroutines.flow.internal.ChannelFlow' appears in /data/app/~~ccBt4dlqHFv3AkedliSnSw==/redacted.package.name.debug-QqdNYvkOKVfFKcKUHZwhVg==/base.apk!classes18.dex)
at kotlinx.coroutines.reactive.PublisherAsFlow.<init>(ReactiveFlow.kt:51)
at kotlinx.coroutines.reactive.PublisherAsFlow.<init>(ReactiveFlow.kt:50)
at kotlinx.coroutines.reactive.ReactiveFlowKt.asFlow(ReactiveFlow.kt:30)
I had a library compiled with
org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.9
My project used a more recent version
org.jetbrains.kotlinx:kotlinx-coroutines-core:1.4.2
this apparently caused a binary incompatibility....
It is troubling to me because asFlow
wasn't marked experimental.
should I open a ticket / tweet to someone about it?
I shouldn't need to release a new version of the library to make it binary compatible with greater versions.
WHY this is DEEPLY troubling:
If the language doesn't guarantee binary backward compatibility with a previous minor version (1.3.x -> 1.4.x) it means that developers will have to constantly update libraries and eventually maintain multiple versions compiled against multiple version of kotlin for projects that still use a previous minor.
THIS IS A NO GO for any language.
Libraries compiled for Java 6 run just fine on Java 13.
I'm not kotlin need to be that conservative, but at least not break backward compatibility on stable api between minors? Deprecate them for a couple of minors is ok. This is not.Marc Knaup
12/11/2020, 5:18 PMDaniele Segato
12/11/2020, 5:20 PMMarc Knaup
12/11/2020, 5:21 PMDaniele Segato
12/11/2020, 5:24 PMMarc Knaup
12/11/2020, 5:25 PMMarc Knaup
12/11/2020, 5:28 PMMarc Knaup
12/11/2020, 5:30 PMMarc Knaup
12/11/2020, 5:30 PMDaniele Segato
12/11/2020, 5:34 PMMarc Knaup
12/11/2020, 5:38 PMNormally, incompatible changes to stable features only land in feature releases.https://kotlinlang.org/releases.html
We ship different types of releases:
• Feature releases (1.x) that bring major changes in the language.
Daniele Segato
12/11/2020, 5:40 PMMarc Knaup
12/11/2020, 5:42 PM• Changed ABI in reactive integrations for Java interoperability (#2182).
Marc Knaup
12/11/2020, 5:43 PMMarc Knaup
12/11/2020, 5:43 PMMarc Knaup
12/11/2020, 5:50 PMDaniele Segato
12/11/2020, 5:58 PMArkadii Ivanov
12/11/2020, 7:16 PMDaniele Segato
12/11/2020, 7:25 PMArkadii Ivanov
12/11/2020, 7:36 PMArkadii Ivanov
12/11/2020, 7:37 PMDaniele Segato
12/11/2020, 7:57 PMgildor
12/12/2020, 6:35 AMgildor
12/12/2020, 6:36 AMDaniele Segato
12/14/2020, 8:11 AMgildor
12/14/2020, 10:23 AMgildor
12/14/2020, 10:26 AMgildor
12/14/2020, 10:27 AMMarc Knaup
12/14/2020, 12:04 PM