Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rburgst/ktor-moshi-issue
sample repo showing a problem with moshi integration and ktor 1.0
https://github.com/rburgst/ktor-moshi-issue
Last synced: 2 days ago
JSON representation
sample repo showing a problem with moshi integration and ktor 1.0
- Host: GitHub
- URL: https://github.com/rburgst/ktor-moshi-issue
- Owner: rburgst
- Created: 2018-11-25T13:27:32.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2018-11-25T13:29:34.000Z (about 6 years ago)
- Last Synced: 2024-11-08T17:53:07.196Z (about 2 months ago)
- Language: Kotlin
- Size: 52.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Sample repo showing a problem with ktor-moshi
see https://github.com/rharter/ktor-moshi/issues/3
1. launch the app in IntelliJ
2. send an http request to http://localhost:8080/json/gson
(see also `./requests.http`)### Expected
a JSON response
### Actual
```
2018-11-25 14:22:11.172 [nettyCallPool-4-1] ERROR Application - Unhandled: GET - /json/gson
java.lang.AbstractMethodError: com.ryanharter.ktor.moshi.MoshiConverter.convertForSend(Lio/ktor/util/pipeline/PipelineContext;Lio/ktor/http/ContentType;Ljava/lang/Object;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
at io.ktor.features.ContentNegotiation$Feature$install$2.invokeSuspend(ContentNegotiation.kt:82)
at io.ktor.features.ContentNegotiation$Feature$install$2.invoke(ContentNegotiation.kt)
at io.ktor.util.pipeline.SuspendFunctionGun.loop(PipelineContext.kt:248)
at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(PipelineContext.kt:63)
at io.ktor.util.pipeline.SuspendFunctionGun.proceed(PipelineContext.kt:111)
at io.ktor.util.pipeline.SuspendFunctionGun.execute(PipelineContext.kt:131)
at io.ktor.util.pipeline.Pipeline.execute(Pipeline.kt:24)
at com.example.ApplicationKt$module$2$2.invokeSuspend(Application.kt:42)
at com.example.ApplicationKt$module$2$2.invoke(Application.kt)
at io.ktor.util.pipeline.SuspendFunctionGun.loop(PipelineContext.kt:248)
at io.ktor.util.pipeline.SuspendFunctionGun.access$loop(PipelineContext.kt:63)
```