alex009
09/27/2018, 2:45 AMUndefined symbols for architecture x86_64:
"_kfun:platform.darwin.objcKniBridge77$darwin(kotlin.native.internal.NativePtr;kotlin.native.internal.NativePtr)platform.darwin.NSObject?", referenced from:
_kfun:io.ktor.client.engine.ios.IosClientEngine.$execute$3.invokeSuspend(kotlin.Result<kotlin.Any?>)kotlin.Any? in combined.o
"_private_functions_<ktor-http-ios>_kfun:io.ktor.http.HttpStatusCode.equals(kotlin.Any?)ValueType_57", referenced from:
_kfun:com.mirbega.russiarunning.network.LiveEventsApi.$processResponse$3.invokeSuspend(kotlin.Result<kotlin.Any?>)kotlin.Any? in combined.o
ld: symbol(s) not found for architecture x86_64
used versions is:
kotlin_version = '1.3.0-rc-57'
kotlin_native_version = '0.9.2'
coroutines_version = '0.26.1-eap13'
serialization_version = '0.8.1-rc13'
ktor_version = '0.9.5-rc13'
anybody get same problem? or know how to fix?olonho
09/27/2018, 5:24 AMsandwwraith
09/27/2018, 12:30 PMe5l
09/27/2018, 12:33 PMalex009
09/27/2018, 2:00 PMalex009
09/27/2018, 2:21 PMalex009
09/28/2018, 2:07 AMkotlin_version = '1.3.0-rc-57'
kotlin_native_version = '0.9.2'
coroutines_version = '0.26.1-rc-conf2'
serialization_version = '0.8.1-rc13'
ktor_version = '0.9.5-rc13-conf2'
and without usage of HttpStatusCode of ktoralex009
09/28/2018, 2:08 AMreturn when (response.status) {
HttpStatusCode.OK -> {
parser(responseJson)
}
HttpStatusCode.Unauthorized -> {
val message = responseJson.jsonObject.getObject("error").getPrimitive("error_message").content
throw UnAuthorizedException(message)
}
else -> {
val message = responseJson.jsonObject.getObject("error").getPrimitiveOrNull("error_message")?.contentOrNull
if (message != null) throw HttpErrorException(message)
val errorJSON = responseJson.jsonObject.getObject("error")
.getObjectOrNull("error_message")
val parsedJsonError = parseJsonError(errorJSON?.toString() ?: "")
throw HttpErrorException(parsedJsonError ?: "")
}
}
and compilation success. but without commenting i got error:
Undefined symbols for architecture x86_64:
"_private_classes_<ktor-http-ios>_io.ktor.http.HttpStatusCode_56", referenced from:
_kfun:com.mirbega.russiarunning.network.LiveEventsApi.$processResponse$3.invokeSuspend(kotlin.Result<kotlin.Any?>)kotlin.Any? in combined.o
"_private_functions_<ktor-http-ios>_kfun:io.ktor.http.HttpStatusCode.equals(kotlin.Any?)ValueType_57", referenced from:
_kfun:com.mirbega.russiarunning.network.LiveEventsApi.$processResponse$3.invokeSuspend(kotlin.Result<kotlin.Any?>)kotlin.Any? in combined.o
ld: symbol(s) not found for architecture x86_64
alex009
09/28/2018, 2:16 AMreturn if(response.status.isSuccess()) {
parser(responseJson)
} else {
val message = responseJson.jsonObject.getObject("error").getPrimitiveOrNull("error_message")?.contentOrNull
if (message != null) throw HttpErrorException(message)
val errorJSON = responseJson.jsonObject.getObject("error")
.getObjectOrNull("error_message")
val parsedJsonError = parseJsonError(errorJSON?.toString() ?: "")
throw HttpErrorException(parsedJsonError ?: "")
}