Hi,
we tried to use compose-richtext to display Markdown in our compose Android App.
Unfortunately, the app is crashing with the latest version (0.11.0), which seems to be related to the Coil Version we are using.
We are using the latest coil version 2.0.0-rc03 and receive the following stacktrace.
Note that when downgrading to 2.0.0-alpha06, everything works fine.
java.lang.NoSuchMethodError: No static method rememberAsyncImagePainter-8BXIMaA(Ljava/lang/Object;ILandroidx/compose/runtime/Composer;II)Lcoil/compose/AsyncImagePainter; in class Lcoil/compose/SingletonAsyncImagePainterKt; or its super classes (declaration of 'coil.compose.SingletonAsyncImagePainterKt' appears in /data/app/~~PGSppQ4FjVn2UYsP16sXHQ==/com.package.develop-UQ2-dt0KxyMNh-356uPjYg==/base.apk!classes21.dex) at com.halilibo.richtext.markdown.RemoteImageKt.RemoteImage(RemoteImage.kt:33) at com.halilibo.richtext.markdown.MarkdownRichTextKt$computeRichTextString$newFormatIndex$3.invoke(MarkdownRichText.kt:107) at com.halilibo.richtext.markdown.MarkdownRichTextKt$computeRichTextString$newFormatIndex$3.invoke(MarkdownRichText.kt:106) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:135) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at com.halilibo.richtext.ui.string.InlineContentKt$reifyInlineContent$1$1.invoke(InlineContent.kt:85) at com.halilibo.richtext.ui.string.InlineContentKt$reifyInlineContent$1$1.invoke(InlineContent.kt:84) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:116) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.foundation.text.CoreTextKt.InlineChildren(CoreText.kt:78) at androidx.compose.foundation.text.BasicTextKt$BasicText$6.invoke(BasicText.kt:234) at androidx.compose.foundation.text.BasicTextKt$BasicText$6.invoke(BasicText.kt:234) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:107) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.foundation.text.BasicTextKt.BasicText-4YKlhWE(BasicText.kt:322) at com.halilibo.richtext.ui.RichTextLocalsKt.Text-4YKlhWE(RichTextLocals.kt:88) at com.halilibo.richtext.ui.RichTextLocalsKt.ClickableText-VhcvRP8(RichTextLocals.kt:125) at com.halilibo.richtext.ui.string.TextKt$Text$2.invoke(Text.kt:44) at com.halilibo.richtext.ui.string.TextKt$Text$2.invoke(Text.kt:38) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:116) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.foundation.layout.BoxWithConstraintsKt$BoxWithConstraints$1$1$measurables$1.invoke(BoxWithConstraints.kt:69) at androidx.compose.foundation.layout.BoxWithConstraintsKt$BoxWithConstraints$1$1$measurables$1.invoke(BoxWithConstraints.kt:69) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:107) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.ui.layout.LayoutNodeSubcompositionsState$subcompose$2$1$1.invoke(SubcomposeLayout.kt:753) at androidx.compose.ui.layout.LayoutNodeSubcompositionsState$subcompose$2$1$1.invoke(SubcomposeLayout.kt:447) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:107) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.runtime.ActualJvm_jvmKt.invokeComposable(ActualJvm.jvm.kt:74) at androidx.compose.runtime.ComposerImpl$doCompose$2$5.invoke(Composer.kt:3164) at androidx.compose.runtime.ComposerImpl$doCompose$2$5.invoke(Composer.kt:3154) at androidx.compose.runtime.SnapshotStateKt__DerivedStateKt.observeDerivedStateRecalculations(DerivedState.kt:252) at androidx.compose.runtime.SnapshotStateKt.observeDerivedStateRecalculations(Unknown Source:1) at androidx.compose.runtime.ComposerImpl.doCompose(Composer.kt:3154) at androidx.compose.runtime.ComposerImpl.composeContent$runtime_release(Composer.kt:3091) at androidx.compose.runtime.CompositionImpl.composeContent(Composition.kt:568)
Hi, we tried to use compose-richtext to display Markdown in our compose Android App. Unfortunately, the app is crashing with the latest version (0.11.0), which seems to be related to the Coil Version we are using. We are using the latest coil version 2.0.0-rc03 and receive the following stacktrace. Note that when downgrading to 2.0.0-alpha06, everything works fine.
java.lang.NoSuchMethodError: No static method rememberAsyncImagePainter-8BXIMaA(Ljava/lang/Object;ILandroidx/compose/runtime/Composer;II)Lcoil/compose/AsyncImagePainter; in class Lcoil/compose/SingletonAsyncImagePainterKt; or its super classes (declaration of 'coil.compose.SingletonAsyncImagePainterKt' appears in /data/app/~~PGSppQ4FjVn2UYsP16sXHQ==/com.package.develop-UQ2-dt0KxyMNh-356uPjYg==/base.apk!classes21.dex) at com.halilibo.richtext.markdown.RemoteImageKt.RemoteImage(RemoteImage.kt:33) at com.halilibo.richtext.markdown.MarkdownRichTextKt$computeRichTextString$newFormatIndex$3.invoke(MarkdownRichText.kt:107) at com.halilibo.richtext.markdown.MarkdownRichTextKt$computeRichTextString$newFormatIndex$3.invoke(MarkdownRichText.kt:106) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:135) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at com.halilibo.richtext.ui.string.InlineContentKt$reifyInlineContent$1$1.invoke(InlineContent.kt:85) at com.halilibo.richtext.ui.string.InlineContentKt$reifyInlineContent$1$1.invoke(InlineContent.kt:84) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:116) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.foundation.text.CoreTextKt.InlineChildren(CoreText.kt:78) at androidx.compose.foundation.text.BasicTextKt$BasicText$6.invoke(BasicText.kt:234) at androidx.compose.foundation.text.BasicTextKt$BasicText$6.invoke(BasicText.kt:234) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:107) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.foundation.text.BasicTextKt.BasicText-4YKlhWE(BasicText.kt:322) at com.halilibo.richtext.ui.RichTextLocalsKt.Text-4YKlhWE(RichTextLocals.kt:88) at com.halilibo.richtext.ui.RichTextLocalsKt.ClickableText-VhcvRP8(RichTextLocals.kt:125) at com.halilibo.richtext.ui.string.TextKt$Text$2.invoke(Text.kt:44) at com.halilibo.richtext.ui.string.TextKt$Text$2.invoke(Text.kt:38) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:116) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.foundation.layout.BoxWithConstraintsKt$BoxWithConstraints$1$1$measurables$1.invoke(BoxWithConstraints.kt:69) at androidx.compose.foundation.layout.BoxWithConstraintsKt$BoxWithConstraints$1$1$measurables$1.invoke(BoxWithConstraints.kt:69) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:107) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.ui.layout.LayoutNodeSubcompositionsState$subcompose$2$1$1.invoke(SubcomposeLayout.kt:753) at androidx.compose.ui.layout.LayoutNodeSubcompositionsState$subcompose$2$1$1.invoke(SubcomposeLayout.kt:447) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:107) at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:34) at androidx.compose.runtime.ActualJvm_jvmKt.invokeComposable(ActualJvm.jvm.kt:74) at androidx.compose.runtime.ComposerImpl$doCompose$2$5.invoke(Composer.kt:3164) at androidx.compose.runtime.ComposerImpl$doCompose$2$5.invoke(Composer.kt:3154) at androidx.compose.runtime.SnapshotStateKt__DerivedStateKt.observeDerivedStateRecalculations(DerivedState.kt:252) at androidx.compose.runtime.SnapshotStateKt.observeDerivedStateRecalculations(Unknown Source:1) at androidx.compose.runtime.ComposerImpl.doCompose(Composer.kt:3154) at androidx.compose.runtime.ComposerImpl.composeContent$runtime_release(Composer.kt:3091) at androidx.compose.runtime.CompositionImpl.composeContent(Composition.kt:568)