https://kotlinlang.org logo
#ktor
Title
# ktor
l

legzo

03/04/2019, 12:12 PM
Hellooo, a quick question for you Kotlin nerds : do you know if it is normal that IntelliJ displays this as an error ? My imports specify :
import kotlinx.io.charsets.Charsets
. I can't see how I can make IntelliJ happy here...
e

e5l

03/04/2019, 12:13 PM
Hi @legzo, could you provide imports?
l

legzo

03/04/2019, 12:46 PM
Hi @e5l, sure thing :
Copy code
import com.fasterxml.jackson.annotation.JsonAutoDetect
import com.fasterxml.jackson.annotation.JsonInclude
import com.fasterxml.jackson.annotation.PropertyAccessor
import com.fasterxml.jackson.databind.DeserializationFeature
import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule
import com.orange.ccmd.connector.logging.ConnectorLogger
import com.orange.ccmd.connector.logging.Logger.logWith
import com.orange.ccmd.connector.logging.NetworkLogging
import com.orange.ccmd.connector.models.FunctionalException
import com.orange.ccmd.connector.models.TechnicalException
import io.ktor.client.HttpClient
import io.ktor.client.call.receive
import io.ktor.client.engine.okhttp.OkHttp
import io.ktor.client.features.auth.basic.BasicAuth
import io.ktor.client.features.json.JacksonSerializer
import io.ktor.client.features.json.JsonFeature
import io.ktor.client.request.HttpRequestBuilder
import io.ktor.client.request.request
import io.ktor.client.response.HttpResponse
import io.ktor.http.HttpMethod
import io.ktor.http.HttpMethod.Companion.Delete
import io.ktor.http.HttpMethod.Companion.Get
import <http://io.ktor.http.HttpMethod.Companion.Post|io.ktor.http.HttpMethod.Companion.Post>
import io.ktor.http.HttpMethod.Companion.Put
import io.ktor.http.HttpStatusCode.Companion.OK
import kotlinx.coroutines.runBlocking
import kotlinx.io.charsets.Charsets
import okhttp3.OkHttpClient
import org.slf4j.LoggerFactory
import java.net.InetSocketAddress
import java.net.Proxy
e

e5l

03/04/2019, 1:28 PM
It looks like an Idea problem. Could you file an issue https://youtrack.jetbrains.com/newIssue?
l

legzo

03/04/2019, 1:58 PM
Sure, I'll do that, thanks
👍 1
Ah ! I found out that if I specify the type explicitly Idea does not complain anymore :
Capture d’écran 2019-03-04 à 15.43.07.png