简体   繁体   English

IntelliJ 无法识别 Kotlin JPA 插件

[英]IntelliJ doesn't recognize Kotlin JPA plugin

I have a Spring Boot project setup with Kotlin and Gradle in IntelliJ Ultimate 2019.3.2.我在 IntelliJ Ultimate 2019.3.2 中使用 Kotlin 和 Gradle 设置了 Spring Boot 项目。 I included the Kotlin JPA plugin in my build.gradle.kts so no-args constructors will be autogenerated for Entities .我在build.gradle.kts包含了 Kotlin JPA 插件,因此将为Entities自动生成无参数构造函数。 This all works fine when I run bootRun from Gradle.当我从 Gradle 运行bootRun时,这一切正常。

IntelliJ doesn't recognize that the JPA plugin is installed though.尽管 IntelliJ 无法识别已安装 JPA 插件。 It gives the below error as I'm developing (note that everything compiles and works fine at runtime, its just this error in IntelliJ that I'm trying to get rid of):它在我开发时给出了以下错误(请注意,一切都在运行时编译并正常工作,它只是我试图摆脱的 IntelliJ 中的这个错误):

在此处输入图片说明

The thing is, IntelliJ recognizes I have the plugin installed as can be seen below in my project's facets (next to the org.jetbrains.kotlin.noarg entry), but it still shows the error above.问题是,IntelliJ 识别出我安装了插件,如下面我的项目方面(在org.jetbrains.kotlin.noarg条目旁边)所示,但它仍然显示上面的错误。 I checked inspections to see if I can disable the inspection but there isn't one for this error.我检查了检查以查看是否可以禁用检查,但没有针对此错误的检查。 How can I get IntelliJ to recognize that my Entity classes are fine?我怎样才能让 IntelliJ 认识到我的Entity类很好?

在此处输入图片说明

You can try to update Kotlin from 1.3.61 to 1.3.70-eap-274.您可以尝试将 Kotlin 从 1.3.61 更新到 1.3.70-eap-274。 And feel free to vote or comment on a similar issue in Kotlin public tracker: https://youtrack.jetbrains.com/issue/KT-36964 .并随时对 Kotlin 公共跟踪器中的类似问题进行投票或评论: https : //youtrack.jetbrains.com/issue/KT-36964 Thank you!谢谢!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM