programing

인식할 수 없는 특성 이름 MODULE(class com.sun.tools.javac.util)입니다.SharedNameTable$NameImppl)

goodsources 2023. 9. 28. 08:22
반응형

인식할 수 없는 특성 이름 MODULE(class com.sun.tools.javac.util)입니다.SharedNameTable$NameImppl)

기본 안드로이드 프로젝트를 안드로이드 S(안드로이드 12 출시 전)로 업데이트할 때 이 빌드 오류가 발생했습니다.

구글에서 오류를 찾았지만 귀중한 안타는 없었습니다.몇 년 전 넷빈스에서 나온 히트곡 하나와 몇 가지 Xamarin 문제.

스택 추적은 아래와 같습니다.

FAILURE: Build completed with 2 failures.

1: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':dependencies:android:kaptDebugKotlin'.
> A failure occurred while executing org.jetbrains.kotlin.gradle.internal.KaptWithoutKotlincTask$KaptExecutionWorkAction
   > java.lang.reflect.InvocationTargetException (no error message)

* Try:
Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Exception is:
org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':dependencies:android:kaptDebugKotlin'.
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.lambda$executeIfValid$1(ExecuteActionsTaskExecuter.java:200)
    at org.gradle.internal.Try$Failure.ifSuccessfulOrElse(Try.java:263)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:198)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:179)
    at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:109)
    at org.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46)
    at org.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:62)
    at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:57)
    at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:56)
    at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:36)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.executeTask(EventFiringTaskExecuter.java:77)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:55)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:52)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:75)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:153)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:62)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.lambda$call$2(DefaultBuildOperationExecutor.java:76)
    at org.gradle.internal.operations.UnmanagedBuildOperationWrapper.callWithUnmanagedSupport(UnmanagedBuildOperationWrapper.java:54)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:76)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:52)
    at org.gradle.execution.plan.LocalTaskNodeExecutor.execute(LocalTaskNodeExecutor.java:41)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:372)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:359)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:352)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:338)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.lambda$run$0(DefaultPlanExecutor.java:127)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.execute(DefaultPlanExecutor.java:191)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.executeNextNode(DefaultPlanExecutor.java:182)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.run(DefaultPlanExecutor.java:124)
    at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64)
    at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:48)
    at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:56)
Caused by: org.gradle.workers.internal.DefaultWorkerExecutor$WorkExecutionException: A failure occurred while executing org.jetbrains.kotlin.gradle.internal.KaptWithoutKotlincTask$KaptExecutionWorkAction
    at org.gradle.workers.internal.DefaultWorkerExecutor$WorkItemExecution.waitForCompletion(DefaultWorkerExecutor.java:336)
    at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForItemsAndGatherFailures(DefaultAsyncWorkTracker.java:142)
    at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForItemsAndGatherFailures(DefaultAsyncWorkTracker.java:94)
    at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForAll(DefaultAsyncWorkTracker.java:80)
    at org.gradle.internal.work.DefaultAsyncWorkTracker.waitForCompletion(DefaultAsyncWorkTracker.java:68)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$3.run(ExecuteActionsTaskExecuter.java:563)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:29)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$1.execute(DefaultBuildOperationRunner.java:26)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:75)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:153)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.run(DefaultBuildOperationRunner.java:56)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.lambda$run$1(DefaultBuildOperationExecutor.java:71)
    at org.gradle.internal.operations.UnmanagedBuildOperationWrapper.runWithUnmanagedSupport(UnmanagedBuildOperationWrapper.java:45)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:71)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:540)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:523)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.access$300(ExecuteActionsTaskExecuter.java:108)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$TaskExecution.executeWithPreviousOutputFiles(ExecuteActionsTaskExecuter.java:271)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$TaskExecution.execute(ExecuteActionsTaskExecuter.java:260)
    at org.gradle.internal.execution.steps.ExecuteStep.lambda$execute$0(ExecuteStep.java:33)
    at org.gradle.internal.execution.steps.ExecuteStep.execute(ExecuteStep.java:33)
    at org.gradle.internal.execution.steps.ExecuteStep.execute(ExecuteStep.java:26)
    at org.gradle.internal.execution.steps.CleanupOutputsStep.execute(CleanupOutputsStep.java:67)
    at org.gradle.internal.execution.steps.CleanupOutputsStep.execute(CleanupOutputsStep.java:36)
    at org.gradle.internal.execution.steps.ResolveInputChangesStep.execute(ResolveInputChangesStep.java:49)
    at org.gradle.internal.execution.steps.ResolveInputChangesStep.execute(ResolveInputChangesStep.java:34)
    at org.gradle.internal.execution.steps.CancelExecutionStep.execute(CancelExecutionStep.java:43)
    at org.gradle.internal.execution.steps.TimeoutStep.executeWithoutTimeout(TimeoutStep.java:73)
    at org.gradle.internal.execution.steps.TimeoutStep.execute(TimeoutStep.java:54)
    at org.gradle.internal.execution.steps.CreateOutputsStep.execute(CreateOutputsStep.java:44)
    at org.gradle.internal.execution.steps.SnapshotOutputsStep.execute(SnapshotOutputsStep.java:54)
    at org.gradle.internal.execution.steps.SnapshotOutputsStep.execute(SnapshotOutputsStep.java:38)
    at org.gradle.internal.execution.steps.BroadcastChangingOutputsStep.execute(BroadcastChangingOutputsStep.java:42)
    at org.gradle.internal.execution.steps.CacheStep.executeWithoutCache(CacheStep.java:159)
    at org.gradle.internal.execution.steps.CacheStep.execute(CacheStep.java:72)
    at org.gradle.internal.execution.steps.CacheStep.execute(CacheStep.java:43)
    at org.gradle.internal.execution.steps.StoreExecutionStateStep.execute(StoreExecutionStateStep.java:44)
    at org.gradle.internal.execution.steps.StoreExecutionStateStep.execute(StoreExecutionStateStep.java:33)
    at org.gradle.internal.execution.steps.RecordOutputsStep.execute(RecordOutputsStep.java:38)
    at org.gradle.internal.execution.steps.RecordOutputsStep.execute(RecordOutputsStep.java:24)
    at org.gradle.internal.execution.steps.SkipUpToDateStep.executeBecause(SkipUpToDateStep.java:92)
    at org.gradle.internal.execution.steps.SkipUpToDateStep.lambda$execute$0(SkipUpToDateStep.java:85)
    at org.gradle.internal.execution.steps.SkipUpToDateStep.execute(SkipUpToDateStep.java:55)
    at org.gradle.internal.execution.steps.SkipUpToDateStep.execute(SkipUpToDateStep.java:39)
    at org.gradle.internal.execution.steps.ResolveChangesStep.execute(ResolveChangesStep.java:76)
    at org.gradle.internal.execution.steps.ResolveChangesStep.execute(ResolveChangesStep.java:37)
    at org.gradle.internal.execution.steps.legacy.MarkSnapshottingInputsFinishedStep.execute(MarkSnapshottingInputsFinishedStep.java:36)
    at org.gradle.internal.execution.steps.legacy.MarkSnapshottingInputsFinishedStep.execute(MarkSnapshottingInputsFinishedStep.java:26)
    at org.gradle.internal.execution.steps.ResolveCachingStateStep.execute(ResolveCachingStateStep.java:94)
    at org.gradle.internal.execution.steps.ResolveCachingStateStep.execute(ResolveCachingStateStep.java:49)
    at org.gradle.internal.execution.steps.CaptureStateBeforeExecutionStep.execute(CaptureStateBeforeExecutionStep.java:79)
    at org.gradle.internal.execution.steps.CaptureStateBeforeExecutionStep.execute(CaptureStateBeforeExecutionStep.java:53)
    at org.gradle.internal.execution.steps.ValidateStep.execute(ValidateStep.java:74)
    at org.gradle.internal.execution.steps.SkipEmptyWorkStep.lambda$execute$2(SkipEmptyWorkStep.java:78)
    at org.gradle.internal.execution.steps.SkipEmptyWorkStep.execute(SkipEmptyWorkStep.java:78)
    at org.gradle.internal.execution.steps.SkipEmptyWorkStep.execute(SkipEmptyWorkStep.java:34)
    at org.gradle.internal.execution.steps.legacy.MarkSnapshottingInputsStartedStep.execute(MarkSnapshottingInputsStartedStep.java:39)
    at org.gradle.internal.execution.steps.LoadExecutionStateStep.execute(LoadExecutionStateStep.java:40)
    at org.gradle.internal.execution.steps.LoadExecutionStateStep.execute(LoadExecutionStateStep.java:28)
    at org.gradle.internal.execution.impl.DefaultWorkExecutor.execute(DefaultWorkExecutor.java:33)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeIfValid(ExecuteActionsTaskExecuter.java:187)
    at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:179)
    at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:109)
    at org.gradle.api.internal.tasks.execution.FinalizePropertiesTaskExecuter.execute(FinalizePropertiesTaskExecuter.java:46)
    at org.gradle.api.internal.tasks.execution.ResolveTaskExecutionModeExecuter.execute(ResolveTaskExecutionModeExecuter.java:62)
    at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:57)
    at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:56)
    at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:36)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.executeTask(EventFiringTaskExecuter.java:77)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:55)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter$1.call(EventFiringTaskExecuter.java:52)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:75)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:153)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:62)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.lambda$call$2(DefaultBuildOperationExecutor.java:76)
    at org.gradle.internal.operations.UnmanagedBuildOperationWrapper.callWithUnmanagedSupport(UnmanagedBuildOperationWrapper.java:54)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:76)
    at org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute(EventFiringTaskExecuter.java:52)
    at org.gradle.execution.plan.LocalTaskNodeExecutor.execute(LocalTaskNodeExecutor.java:41)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:372)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$InvokeNodeExecutorsAction.execute(DefaultTaskExecutionGraph.java:359)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:352)
    at org.gradle.execution.taskgraph.DefaultTaskExecutionGraph$BuildOperationAwareExecutionAction.execute(DefaultTaskExecutionGraph.java:338)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.lambda$run$0(DefaultPlanExecutor.java:127)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.execute(DefaultPlanExecutor.java:191)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.executeNextNode(DefaultPlanExecutor.java:182)
    at org.gradle.execution.plan.DefaultPlanExecutor$ExecutorWorker.run(DefaultPlanExecutor.java:124)
    at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:64)
    at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:48)
    at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:56)
Caused by: java.lang.reflect.InvocationTargetException
    at org.jetbrains.kotlin.gradle.internal.KaptExecution.run(KaptWithoutKotlincTask.kt:288)
    at org.jetbrains.kotlin.gradle.internal.KaptWithoutKotlincTask$KaptExecutionWorkAction.execute(KaptWithoutKotlincTask.kt:243)
    at org.gradle.workers.internal.DefaultWorkerServer.execute(DefaultWorkerServer.java:63)
    at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:67)
    at org.gradle.workers.internal.NoIsolationWorkerFactory$1$1.create(NoIsolationWorkerFactory.java:63)
    at org.gradle.internal.classloader.ClassLoaderUtils.executeInClassloader(ClassLoaderUtils.java:97)
    at org.gradle.workers.internal.NoIsolationWorkerFactory$1.lambda$execute$0(NoIsolationWorkerFactory.java:63)
    at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:44)
    at org.gradle.workers.internal.AbstractWorker$1.call(AbstractWorker.java:41)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:200)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$CallableBuildOperationWorker.execute(DefaultBuildOperationRunner.java:195)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:75)
    at org.gradle.internal.operations.DefaultBuildOperationRunner$3.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:153)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.execute(DefaultBuildOperationRunner.java:68)
    at org.gradle.internal.operations.DefaultBuildOperationRunner.call(DefaultBuildOperationRunner.java:62)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.lambda$call$2(DefaultBuildOperationExecutor.java:76)
    at org.gradle.internal.operations.UnmanagedBuildOperationWrapper.callWithUnmanagedSupport(UnmanagedBuildOperationWrapper.java:54)
    at org.gradle.internal.operations.DefaultBuildOperationExecutor.call(DefaultBuildOperationExecutor.java:76)
    at org.gradle.workers.internal.AbstractWorker.executeWrappedInBuildOperation(AbstractWorker.java:41)
    at org.gradle.workers.internal.NoIsolationWorkerFactory$1.execute(NoIsolationWorkerFactory.java:60)
    at org.gradle.workers.internal.DefaultWorkerExecutor.lambda$submitWork$2(DefaultWorkerExecutor.java:200)
    at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runExecution(DefaultConditionalExecutionQueue.java:215)
    at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.runBatch(DefaultConditionalExecutionQueue.java:164)
    at org.gradle.internal.work.DefaultConditionalExecutionQueue$ExecutionRunner.run(DefaultConditionalExecutionQueue.java:131)
    ... 3 more
Caused by: java.lang.AssertionError: annotationType(): unrecognized Attribute name MODULE (class com.sun.tools.javac.util.SharedNameTable$NameImpl)
    at com.sun.tools.javac.util.Assert.error(Assert.java:133)
    at com.sun.tools.javac.code.TypeAnnotations.annotationType(TypeAnnotations.java:231)
    at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.separateAnnotationsKinds(TypeAnnotations.java:294)
    at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.visitVarDef(TypeAnnotations.java:1164)
    at com.sun.tools.javac.tree.JCTree$JCVariableDecl.accept(JCTree.java:852)
    at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
    at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.scan(TypeAnnotations.java:275)
    at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:57)
    at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.visitClassDef(TypeAnnotations.java:1042)
    at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:693)
    at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
    at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.scan(TypeAnnotations.java:275)
    at com.sun.tools.javac.code.TypeAnnotations$1.run(TypeAnnotations.java:127)
    at com.sun.tools.javac.comp.Annotate.flush(Annotate.java:152)
    at com.sun.tools.javac.comp.Annotate.enterDone(Annotate.java:129)
    at com.sun.tools.javac.comp.Enter.complete(Enter.java:512)
    at com.sun.tools.javac.comp.Enter.main(Enter.java:471)
    at com.sun.tools.javac.main.JavaCompiler.enterTrees(JavaCompiler.java:982)
    at org.jetbrains.kotlin.kapt3.base.AnnotationProcessingKt.doAnnotationProcessing(annotationProcessing.kt:83)
    at org.jetbrains.kotlin.kapt3.base.AnnotationProcessingKt.doAnnotationProcessing$default(annotationProcessing.kt:31)
    at org.jetbrains.kotlin.kapt3.base.Kapt.kapt(Kapt.kt:45)
    ... 28 more

이 문제를 극복하기 위해 제가 할 수 있는 조치가 있을까요?

이는 안드로이드 빌드에서 다음과 같은 조합으로 발생합니다.

  • completeSdkVersion31(또는 나중에)을 사용하면,
  • JDK8로.
  • 어딘가에 람다 스타일 관련 코드가 있는 경우(다른 오류는 발생하지 않을 수 있음).

현재 기본 Android 툴체인이 JDK11로 이동했으므로, 적어도 Android API 대상 버전을 31(또는 그 이후)로 변경하는 경우에는 JDK11을 사용해야 합니다.


AS Arctic Fox에서 gradle jdk를 업데이트하는 경로:

Settings > Build, Execution, Deployment > Build Tools > Gradle > Gradle JDK

11을 선택하면 빌드가 성공해야 합니다.

이 옵션이 없으면 Android Studio를 업그레이드합니다.

저는 빌드 컨테이너에서 이 문제를 해결하고 있었지만 안드로이드 스튜디오를 통해 빌드할 때는 그렇지 않았습니다.

두 환경의 차이점은 JDK 버전이었습니다.안드로이드 스튜디오는 JDK 11을 사용하고 있었고 빌드 컨테이너는 openjdk-8을 사용하고 있었습니다.

이 수정은 컨테이너의 JDK 버전을 openjdk-11로 업데이트하는 중이었습니다.

안드로이드 12는 JDK 11+가 필요한 것 같습니다.

Android Studio에서는 8에서 11까지 JDK를 업데이트할 수 있습니다.

DevOps 도구를 사용하는 경우 JDK를 11로 업데이트해야 합니다. 그렇지 않으면 디버그 빌드 apk를 컴파일하지 않습니다.

안드로이드 31(컴파일 Sdk 버전)은 JDK 11+가 필요한 것 같습니다.

Android Studio에서는 8에서 11까지 JDK를 업데이트할 수 있습니다.

File -> Project Structure -> Sdk Location -> Gradle Settings -> Gradle SDK

코르도바, 플러터, 리액트 네이티브, 콘덴서에서 사용할 수 있습니다.제가 구현한 것 중 하나가 코드에 람다 표현을 넣었기 때문입니다.

JDK 11을 다운로드합니다. 예를 들어 공식 사이트: https://www.oracle.com/java/technologies/downloads/ (그러나 계정이 필요합니다.) 또는 https://jdk.java.net/ (straight 링크를 하위 사이트로 이동하면 WindowsLinux용 링크를 찾을 수 있습니다.)

아는 경로와 접근 가능한 경로가 있는 어딘가에 짐을 풀고 배치합니다(어디에 있는지 모를 경우 - 현재 사용되는 JDK가 있는 다음 단계를 확인하십시오).

에서 Android Studio 에서합니다를 합니다.File -> Project Structure -> SDK Location - "에서 JDK다를 합니다. 여기에 새 버전의 JDK 경로를 입력한 다음 "적용" 버튼을 클릭합니다.

고르다File -> Invalidate Caches / Restart"을 수행하고,가 새 종속성을 종속성을 고 하고"운, AS다 JDK합니다("Apply용)"의).

같은 문제가 생겨서 안드로이드 스튜디오를 업데이트해야 했습니다.이제 jdk 1.8.0_291과도 연동이 됩니다.Arctic fox 2020.3.1 버전 Android studio로 업데이트 했습니다.

같은 문제가 발생했는데, JDK8이 안드로이드-12의 안드로이드.jar와 호환되지 않는 것 같습니다.

하지만 안드로이드-11은 효과가 있었습니다.

제 요구에 따라 안드로이드-11의 안드로이드.jar만 컴파일하도록 변경하면 앱을 성공적으로 구축할 수 있습니다.

Mac용 Visual studio의 경우: 다음 위치와 같이 Microsoft에서 Java 11을 다운로드하여 설치합니다. https://download.visualstudio.microsoft.com/download/pr/0df4ef07-5a9a-4fc2-8ae6-0b6731685d25/fb07059f75bd3916b490f2d266bc94c0/microsoft-jdk-11.0.12.7.1-macos-x64.pkg

그런 다음 도구->SDK 관리자, 위치 탭으로 이동하여 Java 위치가 최근에 설치한 위치인지 확인합니다(예: /Library/Java/JavaVirtualMachines/microsoft-17.jdk/Contents/Home).

프로젝트를 재구성합니다.

제 경우 오류는 Unity를 v2020.3.33(2021.3.0)으로 업데이트한 후 이전 버전의 Android Gradle Plugin(3.6.4)을 사용하는 것으로 나타났습니다.

업데이트하나에서 Unity - 이전 버전의 플러그인과 호환되지 않는 Gradle의 업데이트 및 버전.

해결책

  • Android 12 다운로드 (API 31) - Unity에서 Target API로 자동 사용 (Android 12L (API 32)도 가능 - 상관 없음)

  • 파일베이스프로젝트에서 Android Gradle Plugin 버전을 4.0.1로 설정합니다.template.gradle

    클래스패스 'com. android.tools.build:gradle:4.0.1'

  • Android Build Tools가 버전 30.0.+를 남김(31 이상과 동일) - Unity와 호환되지 않음).

앱센터에서 이 오류가 발생하는 사용자는 빌드 구성에 아래 환경 변수를 추가할 수 있습니다.

JAVA_HOME: $(JAVA_HOME_11_X64)

Visual Studio 2019에서 이 문제를 겪고 있는 사람이 있다면 Android SDK Manager(Tools > Android > Android SDK Manager)를 Android 12로 업데이트해야 합니다.

JDK 11의 설치 후 모든 단계가 포함된 아래 링크를 참조하십시오.

https://github.com/xamarin/xamarin-android/wiki/JDK-11-Warning#visual-studio-2019

이것은 @top-master가 제공한 답변에 더해지고 있습니다.리액트 네이티브 런 안드로이드를 사용하여 빌드를 실행했을 때 실패했지만 안드로이드 스튜디오에서 통과되었습니다.안드로이드 스튜디오는 현지에서 사용하던 것과는 다른 JDK를 사용하고 있었던 것으로 드러났습니다.

만약 그렇다면, 라면, 요, 를 ls -la /Library/Java/JavaVirtualMachines설치한 JDK를 확인합니다.이것을 업그레이드하면 다음과 같습니다.brew install --cask adoptopenjdk/openjdk/adoptopenjdk11효과가 있었습니다.

compileSdkVersion을 31로 업데이트한 후에 Ionic Dashboard에서 Android 앱을 만들 때 같은 오류가 발생했습니다.수정 방법은 https://ionic.io/docs/appflow/cookbook/override-java-version 환경 변수를 사용하여 Ionomic이 Java v11을 사용하도록 강제하는 것이었습니다.

저의 경우 데이터 바인딩으로 인해 이 오류가 발생했는데, 루트 태그를 제거했을 때 레이아웃 파일에서 이 오류가 사라졌습니다.

데이터 바인딩을 사용하고 싶어하기 때문에 이 방법이 해결되지 않을 수도 있지만 누군가에게 도움이 될 수도 있습니다.

여전히 문제에 직면한 사람은 build.gradle 파일 프로젝트 수준에서 내 솔루션을 사용해 보십시오.

classpath 'com.android.tools.build:gradle:4.1.3'

저는 JDK 11을 다운받고 floter를 업그레이드한 후 이 오류가 발생했습니다.

먼저 https://stackoverflow.com/a/76172567/840958 의 지침을 따르는 것으로 시작합니다.

만약 효과가 없다면, 이 오류를 해결해 준 것은 다음과 같습니다.

  1. https://www.openlogic.com/openjdk-downloads 에서 JDK v11을 다운로드하고 설치합니다.그런 다음 다음 구성을 설정해야 합니다.
  • android/build.gradlebuildscript
buildscript {
    ext.kotlin_version = '1.7.10'
    ...
}
  • 에서도.android/build.gradle을 에 합니다.
dependencies {
    classpath 'com.android.tools.build:gradle:7.2.2'
    classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    ...
}
  • android/app/build.gradle
dependencies {
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
    ...
}
  • 에서도.android/app/build.gradle에,android최신 정보를 제공합니다.compileSdkVersion그리고.targetSdkVersion다음과 같은 경우:
android {
    compileSdkVersion flutter.compileSdkVersion
    ...
}
defaultConfig {
    targetSdkVersion flutter.targetSdkVersion
    ...
}
  • 에서도.android/app/build.gradle, 추가 또는 업데이트:
compileOptions {
    sourceCompatibility JavaVersion.VERSION_1_8
    targetCompatibility JavaVersion.VERSION_1_8
    ...
}

그리고.

kotlinOptions {
    jvmTarget = '1.8'
}
  1. https://stackoverflow.com/a/76172567/840958 의 지침에 따라 Flutter 앱에서 사용할 JDK 그라들을 설정합니다.

  2. build.gradle는 이전 를 가지고 .는 그라들는 '레포지토리'고,다.

    allprojects {
        repositories {
          ...
          tasks.withType(JavaCompile).configureEach {
             javaCompiler = javaToolchains.compilerFor {
                languageVersion = JavaLanguageVersion.of(8)
             }
           }
        }
    }
    
  3. gradle의 이전 버전을 사용하는 저장소에 대한 모든 참조를 제거합니다.

jcenter()

그리고.

maven { url 'https://maven.fabric.io/public' }

  1. :gradle.properties제거(존재하는 경우):

android.enableR8=true

  1. :app/build.gradle제거(존재하는 경우):

useProguard true

그리고.

apply plugin: 'io.fabric'

jSpecify's를 사용하기 시작했을 때 안드로이드가 아닌 Java 프로젝트를 위해 사용했습니다.NullMarked주석.여러 번의 철저한 세척(mvn clean그리고.git clean -Xfd도움이 되지 않았고, 단지 a.git revert이 주석을 추가하는 것이 도움이 되었습니다.

이것은 자바8 프로젝트를 위한 것이었습니다.

언급URL : https://stackoverflow.com/questions/68344424/unrecognized-attribute-name-module-class-com-sun-tools-javac-util-sharednametab

반응형