Why httpGet() causes a com.github.kittinunf.fuel.core.BubbleFuelError: null?
See original GitHub issueDescription
I have a rest call realized by fuel library in my Android app Kotlin project. While attempting to call httpGet I get this
Caused by: com.github.kittinunf.fuel.core.BubbleFuelError: null com.github.kittinunf.fuel.core.FuelError$Companion.wrap(FuelError.kt:84) 03-06 11:32:39.112 6328-6328/com.example.demo I/System.out: com.github.kittinunf.fuel.core.requests.RequestTask.executeRequest(RequestTask.kt:24) com.github.kittinunf.fuel.core.requests.RequestTask.call(RequestTask.kt:44) com.github.kittinunf.fuel.core.requests.RequestTask.call(RequestTask.kt:14) com.github.kittinunf.fuel.core.DeserializableKt.response(Deserializable.kt:166) com.github.kittinunf.fuel.core.requests.DefaultRequest.responseObject(DefaultRequest.kt:463)
Question
Most probably the response seem null, and it fails during deserialization? What can I do there?
Issue Analytics
- State:
- Created 5 years ago
- Comments:10 (3 by maintainers)
Top GitHub Comments
I can’t figure out why this is not working for me:
val (_,_,result )= Fuel.get(requestUrl).responseString()
And this works fine:
I would like to work as in the first example, because I would like to return this result.
Hello, Effectively, it was an error of inattention, my synchronous request was in the android main thread. A beginner’s mistake. I should have answered faster to avoid wasting your time. I’m sorry. Anyway, thank you for the modification, I just reproduced this problem and the error is clearer. I think you can close this issue. Sorry again.