更新至Android Studio 3.0.获得“未配置Kotlin"的信息.错误 [英] Updated to Android Studio 3.0. Getting a "Kotlin not configured" error

查看:776
本文介绍了更新至Android Studio 3.0.获得“未配置Kotlin"的信息.错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚更新到Android Studio 3.0,并且在现有项目中遇到此错误:

I just updated to Android Studio 3.0 and I'm getting this error with an existing project:

未配置Kotlin

Kotlin not configured

当我转到工具> Kotlin>在项目中配置Kotlin 时,出现一条错误消息,提示"没有可用的配置器".还会出现以下带有红色Java的错误:

When I go to Tools>Kotlin>Configure Kotlin in Project, I get an error saying "no configurators available". Also get the error below with the red java:

我也尝试过:

  • 重新启动
  • 清理并重建
  • 使缓存/重启无效.

推荐答案

我首先尝试了使用无效缓存/重新启动选项,但它对我没有帮助.

I first tried with invalidate cache/ restart option but it doesn't help me.

当我在项目的gradle文件中将Kotlin更新为1.1.60时,问题就解决了.

When I updated Kotlin to 1.1.60 in project's gradle file, problem is solved.

此外,在应用程序的gradle中将其用于stdlib

Also, use this in app's gradle for stdlib

implementation "org.jetbrains.kotlin:kotlin-stdlib:1.1.60" 

代替

implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:1.1.60"

这篇关于更新至Android Studio 3.0.获得“未配置Kotlin"的信息.错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆