-
-
Notifications
You must be signed in to change notification settings - Fork 153
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: image loading when using markdown img and bigImageUrl
When receiving an image with the same image in the markdown body and in the extras client::notification.bigImageUrl, then there is a clash on the file system. One request succeeds and the other fails with the following error. This commit ensures that there is only one cail image loader instance, so that there shouldn't be file system race conditions. WebSocket(1): received message {"id":845,"appid":21,...} Failed - http://192.168.178.2:8000/1.jpg?v=1718369188 - java.lang.IllegalStateException: closed java.lang.IllegalStateException: closed at okio.RealBufferedSource.rangeEquals(RealBufferedSource.kt:466) at okio.RealBufferedSource.rangeEquals(RealBufferedSource.kt:130) at coil.decode.SvgDecodeUtils.isSvg(DecodeUtils.kt:19) at coil.decode.SvgDecoder$Factory.isApplicable(SvgDecoder.kt:104) at coil.decode.SvgDecoder$Factory.create(SvgDecoder.kt:99) at coil.ComponentRegistry.newDecoder(ComponentRegistry.kt:100) at coil.intercept.EngineInterceptor.decode(EngineInterceptor.kt:197) at coil.intercept.EngineInterceptor.access$decode(EngineInterceptor.kt:42) at coil.intercept.EngineInterceptor$execute$executeResult$1.invokeSuspend(EngineInterceptor.kt:131) at coil.intercept.EngineInterceptor$execute$executeResult$1.invoke(EngineInterceptor.kt) at coil.intercept.EngineInterceptor$execute$executeResult$1.invoke(EngineInterceptor.kt) at kotlinx.coroutines.intrinsics.UndispatchedKt.startUndispatchedOrReturn(Undispatched.kt:78) at kotlinx.coroutines.BuildersKt__Builders_commonKt.withContext(Builders.common.kt:167) at kotlinx.coroutines.BuildersKt.withContext(Unknown Source) at coil.intercept.EngineInterceptor.execute(EngineInterceptor.kt:130) at coil.intercept.EngineInterceptor.access$execute(EngineInterceptor.kt:42) at coil.intercept.EngineInterceptor$execute$1.invokeSuspend(EngineInterceptor.kt) at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33) at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:108) at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:115) at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:103) at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:584) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:793) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:697) at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:684) Successful (NETWORK) - http://192.168.178.2:8000/1.jpg?v=1718369188
- Loading branch information
Showing
5 changed files
with
53 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters