EmmyLua / IntelliJ-EmmyLua

Lua IDE/Debugger Plugin for IntelliJ IDEA
https://emmylua.github.io
Apache License 2.0
1.74k stars 293 forks source link

Can't build the plugin locally #396

Closed pouwelsjochem closed 3 years ago

pouwelsjochem commented 3 years ago

Environment(环境)

name version
IDEA version IC2020.3
EmmyLua version 1.3.5
OS macOS Big Sur

What are the steps to reproduce this issue?(重现步骤?)

Follow the README.md instructions to build the project

What happens?(出现什么问题?)

After executing ./gradlew build_182 there's an error in Task :IntelliJ-EmmyLua:compileKotlin

What were you expecting to happen?(期望?)

The plugin to build

Any logs, error output, etc?(有没有什么log, error输出?)

> Task :IntelliJ-EmmyLua:compileKotlin
w: Runtime JAR files in the classpath should have the same version. These files were found in the classpath:
    /Users/jochem/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.4.20/9be77b243a362b745e365f286627b8724337009c/kotlin-stdlib-1.4.20.jar (version 1.4)
    /Users/jochem/.gradle/caches/modules-2/files-2.1/com.jetbrains.intellij.idea/ideaIU/182.2371.4/371c31d2031677e52f2105fd5e0069a3f6c317be/ideaIU-182.2371.4/lib/kotlin-reflect.jar (version 1.2)
    /Users/jochem/.gradle/caches/modules-2/files-2.1/com.jetbrains.intellij.idea/ideaIU/182.2371.4/371c31d2031677e52f2105fd5e0069a3f6c317be/ideaIU-182.2371.4/lib/kotlin-stdlib-jdk7.jar (version 1.2)
    /Users/jochem/.gradle/caches/modules-2/files-2.1/com.jetbrains.intellij.idea/ideaIU/182.2371.4/371c31d2031677e52f2105fd5e0069a3f6c317be/ideaIU-182.2371.4/lib/kotlin-stdlib-jdk8.jar (version 1.2)
    /Users/jochem/.gradle/caches/modules-2/files-2.1/com.jetbrains.intellij.idea/ideaIU/182.2371.4/371c31d2031677e52f2105fd5e0069a3f6c317be/ideaIU-182.2371.4/lib/kotlin-stdlib.jar (version 1.2)
    /Users/jochem/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib-common/1.4.20/c6761d7805b5312302f2bbd78cda68c976ce0c70/kotlin-stdlib-common-1.4.20.jar (version 1.4)
w: Consider providing an explicit dependency on kotlin-reflect 1.4 to prevent strange errors
w: Some runtime JAR files in the classpath have an incompatible version. Consider removing them from the classpath
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/compat/com/intellij/codeInsight/daemon/AbstractLineMarkerProvider.kt: (22, 5): 'collectSlowLineMarkers' overrides nothing
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/compat/com/intellij/codeInsight/daemon/LuaLineMarkerInfo.kt: (35, 12): None of the following functions can be called with the arguments supplied: 
public constructor LineMarkerInfo<T : PsiElement!>(p0: TypeVariable(T), p1: TextRange, p2: Icon!, p3: Int, p4: Function<in TypeVariable(T)!, String!>?, p5: GutterIconNavigationHandler<TypeVariable(T)!>?, p6: GutterIconRenderer.Alignment) defined in com.intellij.codeInsight.daemon.LineMarkerInfo
public constructor LineMarkerInfo<T : PsiElement!>(p0: TypeVariable(T), p1: Int, p2: Icon!, p3: Int, p4: Function<in TypeVariable(T)!, String!>?, p5: GutterIconNavigationHandler<TypeVariable(T)!>?, p6: GutterIconRenderer.Alignment) defined in com.intellij.codeInsight.daemon.LineMarkerInfo
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/compat/com/intellij/openapi/diagnostic/LuaErrorReportSubmitter.kt: (24, 11): 'submit' overrides nothing
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LargerFileAnnotator.kt: (34, 18): Unresolved reference: newAnnotation
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (19, 37): Unresolved reference: AnnotationBuilder
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (58, 116): Unresolved reference: AnnotationBuilder
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (59, 50): Unresolved reference: newSilentAnnotation
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (59, 95): Unresolved reference: newAnnotation
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (61, 13): Unresolved reference. None of the following candidates is applicable because of receiver type mismatch: 
private fun MatchResult.range(): IntRange defined in kotlin.text
private fun MatchResult.range(groupIndex: Int): IntRange defined in kotlin.text
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (62, 13): Can't inline 'action' here: it may contain non-local returns. Add 'crossinline' modifier to parameter declaration 'action'
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (63, 13): Unresolved reference: create
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/annotator/LuaAnnotator.kt: (67, 91): Unresolved reference: AnnotationBuilder
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/LuaLineMarkerProvider.kt: (48, 1): Class 'LuaLineMarkerProvider' is not abstract and does not implement abstract base class member public abstract fun collectSlowLineMarkers(p0: (Mutable)List<PsiElement!>, p1: (Mutable)Collection<LineMarkerInfo<(raw) PsiElement!>!>): Unit defined in com.intellij.codeInsight.daemon.AbstractLineMarkerProvider
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightExitPointsHandler.kt: (33, 1): Class 'LuaHighlightExitPointsHandler' is not abstract and does not implement abstract base class member protected/*protected and package*/ abstract fun selectTargets(p0: (Mutable)List<PsiElement!>!, p1: Consumer<(Mutable)List<PsiElement!>!>!): Unit defined in com.intellij.codeInsight.highlighting.HighlightUsagesHandlerBase
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightExitPointsHandler.kt: (39, 5): 'selectTargets' overrides nothing
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightUsagesHandlerFactory.kt: (64, 28): Object is not abstract and does not implement abstract base class member protected/*protected and package*/ abstract fun selectTargets(p0: (Mutable)List<PsiElement!>!, p1: Consumer<(Mutable)List<PsiElement!>!>!): Unit defined in com.intellij.codeInsight.highlighting.HighlightUsagesHandlerBase
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightUsagesHandlerFactory.kt: (65, 25): 'selectTargets' overrides nothing
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightUsagesHandlerFactory.kt: (87, 9): Class 'ReferenceHighlightHandler' is not abstract and does not implement abstract base class member protected/*protected and package*/ abstract fun selectTargets(p0: (Mutable)List<PsiElement!>!, p1: Consumer<(Mutable)List<PsiElement!>!>!): Unit defined in com.intellij.codeInsight.highlighting.HighlightUsagesHandlerBase
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightUsagesHandlerFactory.kt: (103, 5): 'selectTargets' overrides nothing
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightUsagesHandlerFactory.kt: (121, 9): Class 'LoopHandler' is not abstract and does not implement abstract base class member protected/*protected and package*/ abstract fun selectTargets(p0: (Mutable)List<PsiElement!>!, p1: Consumer<(Mutable)List<PsiElement!>!>!): Unit defined in com.intellij.codeInsight.highlighting.HighlightUsagesHandlerBase
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/codeInsight/highlighting/LuaHighlightUsagesHandlerFactory.kt: (130, 5): 'selectTargets' overrides nothing
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/errorreporting/error-report.kt: (167, 22): Unresolved reference: getPlugin
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/errorreporting/error-report.kt: (256, 20): Unresolved reference: getPlugin
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/errorreporting/error-report.kt: (257, 54): Unresolved reference: name
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/errorreporting/error-report.kt: (258, 60): Unresolved reference: version
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/psi/LuaFileUtil.kt: (41, 48): Unresolved reference: getPlugin
e: /Users/jochem/Projects/Java/IntelliJ-EmmyLua/src/main/java/com/tang/intellij/lua/psi/LuaFileUtil.kt: (47, 48): Unresolved reference: getPlugin

> Task :IntelliJ-EmmyLua:compileKotlin FAILED
> Task :build_182 FAILED

FAILURE: Build failed with an exception.

Any other comments?(其它说明)

I also tried different branches, tags which also resulted in no success

tangzx commented 3 years ago

Sorry, readme was out of date. Since the new version of IDEA is 203, we should do some change like this

Build environment requirements

pouwelsjochem commented 3 years ago

Thanks! It worked