本文介绍了插件 'org.jetbrains.kotlin' 初始化失败,将被禁用.请重新启动 Android Studio的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Android Studio 的 Kotlin 插件更新后,它停止工作.插件自动禁用.下面是我得到的错误.

After Android Studio's Kotlin plugin update, It stopped working. Plugin is getting disabled automatically. Below error I am getting.

com.intellij.openapi.extensions.impl.PicoPluginExtensionInitializationException: Duplicate registration for EP: org.jetbrains.uast.uastLanguagePlugin: original plugin com.intellij, new plugin org.jetbrains.kotlin
at com.intellij.openapi.extensions.impl.ExtensionsAreaImpl.registerExtensionPoint(ExtensionsAreaImpl.java:286)
at com.intellij.openapi.extensions.impl.ExtensionsAreaImpl.registerExtensionPoint(ExtensionsAreaImpl.java:128)
at com.intellij.ide.plugins.IdeaPluginDescriptorImpl.registerExtensionPoints(IdeaPluginDescriptorImpl.java:328)
at com.intellij.ide.plugins.PluginManagerCore.registerExtensionPointsAndExtensions(PluginManagerCore.java:1352)
at com.intellij.ide.plugins.PluginManagerCore.initializePlugins(PluginManagerCore.java:1264)
at com.intellij.ide.plugins.PluginManagerCore.initPlugins(PluginManagerCore.java:1393)
at com.intellij.ide.plugins.PluginManagerCore.getPlugins(PluginManagerCore.java:121)
at com.intellij.openapi.components.impl.ComponentManagerImpl.getComponentConfigs(ComponentManagerImpl.java:302)
at com.intellij.openapi.components.impl.ComponentManagerImpl.init(ComponentManagerImpl.java:95)
at com.intellij.openapi.application.impl.ApplicationImpl.load(ApplicationImpl.java:425)
at com.intellij.openapi.application.impl.ApplicationImpl.load(ApplicationImpl.java:411)
at com.intellij.idea.IdeaApplication.run(IdeaApplication.java:206)
at com.intellij.idea.MainImpl$1.lambda$null$0(MainImpl.java:49)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:762)
at java.awt.EventQueue.access$500(EventQueue.java:98)
at java.awt.EventQueue$3.run(EventQueue.java:715)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:80)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:732)
at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:343)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

推荐答案

解决方案 1:升级插件

首先进入工具菜单 > 选择 Kotlin > 配置 Kotlin 插件更新 > 选择一个 kotlin 插件 &按下载(稳定或抢先体验,我选择抢先体验来解决此问题)

Solution 1: Upgrade Plugin

First go to Tools menu > Select Kotlin > Configure Kotlin Plugin Updates > Select one of the kotlin plugin & press download (stable or early access, i chose early access to solve this issue)

最后在build.gradle(Project:)中修改kotlin版本,根据下载版本

And finally change the kotlin version in build.gradle(Project:) according to thedownloaded version


解决方案 2:降级插件

如果您在 ma​​c 上,请按:Command + ,打开首选项,然后选择插件 &搜索 kotlin &卸载它,它会回滚到以前的版本:1.1.51

If your on mac then press: Command + , to open preference, then select plugin & search for kotlin & uninstall it, it will rollback to previous version: 1.1.51

Windows 机器上,按Control + Alt + S 打开设置对话框,然后选择插件&搜索 kotlin &卸载它,它会回滚到以前的版本:1.1.51

On Windows machine, press Control + Alt + S to open settings dialog, then select plugins & search for kotlin & uninstall it, it will rollback to previous version: 1.1.51

请注意:不要在插件中取消选中 kotlin 否则它会禁用 kotlin &无法识别 kotlin 文件 &语法

Please Note: Do not uncheck kotlin in plugins else it will disable kotlin & fail to recognise kotlin file & syntax

这篇关于插件 'org.jetbrains.kotlin' 初始化失败,将被禁用.请重新启动 Android Studio的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-24 12:08