-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MissingFieldException: Field 'other_locations' when analyze with sonar-java plugin #4
Comments
@subotaii Could you please send me the sample of sonar-java plugin output. I can't change the contract if I don't know the output of that plugin. You can run this command: Thank you in advance! |
Hello Nhat,
I don't have any problem when i execute the analysis from command line
(codeclimate
analyze -f json > result.json), the resulting json seems good and there is
no item 'other_locations'.
*Stacktrace of the execution of your plugin :*
kotlinx.serialization.MissingFieldException: Field 'other_locations' is
required, but it was missing
at
net.ntworld.codeCleaner.codeClimate.internal.AnalyzedIssueImpl.<init>(AnalyzedIssueImpl.kt)
at
net.ntworld.codeCleaner.codeClimate.internal.AnalyzedIssueImpl$$serializer.deserialize(AnalyzedIssueImpl.kt)
at
net.ntworld.codeCleaner.codeClimate.internal.AnalyzedIssueImpl$$serializer.deserialize(AnalyzedIssueImpl.kt:9)
at
kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:33)
at
kotlinx.serialization.json.internal.AbstractJsonTreeInput.decodeSerializableValue(TreeJsonInput.kt:43)
at kotlinx.serialization.CoreKt.decode(Core.kt:79)
at
kotlinx.serialization.json.internal.TreeJsonInputKt.readJson(TreeJsonInput.kt:22)
at
kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:41)
at
kotlinx.serialization.json.internal.StreamingJsonInput.decodeSerializableValue(StreamingJsonInput.kt:29)
at
kotlinx.serialization.ElementValueDecoder.decodeSerializableElement(ElementWise.kt:142)
at
kotlinx.serialization.internal.ListLikeSerializer.readItem(CollectionSerializers.kt:98)
at
kotlinx.serialization.internal.AbstractCollectionSerializer.readItem$default(CollectionSerializers.kt:70)
at
kotlinx.serialization.internal.AbstractCollectionSerializer.patch(CollectionSerializers.kt:51)
at
kotlinx.serialization.internal.AbstractCollectionSerializer.deserialize(CollectionSerializers.kt:61)
at
kotlinx.serialization.json.internal.PolymorphicKt.decodeSerializableValuePolymorphic(Polymorphic.kt:33)
at
kotlinx.serialization.json.internal.StreamingJsonInput.decodeSerializableValue(StreamingJsonInput.kt:29)
at kotlinx.serialization.CoreKt.decode(Core.kt:79)
at kotlinx.serialization.json.Json.parse(Json.kt:152)
at net.ntworld.codeCleaner.Serializer.parse(Serializer.kt:30)
at net.ntworld.codeCleaner.Serializer.parseIssues(Serializer.kt:39)
at
net.ntworld.codeCleaner.quality.CodeQualityParser.parse(CodeQualityParser.kt:19)
at
net.ntworld.codeCleaner.CodeQualityManager.create(CodeQualityManager.kt:17)
at
net.ntworld.codeCleaner.commandHandler.CreateCodeQualityCommandHandler.handle(CreateCodeQualityCommandHandler.kt:11)
at
net.ntworld.codeCleaner.commandHandler.CreateCodeQualityCommandHandler.handle(CreateCodeQualityCommandHandler.kt:9)
at
net.ntworld.foundation.cqrs.CommandHandler$DefaultImpls.execute(CommandHandler.kt:10)
at
net.ntworld.codeCleaner.commandHandler.CreateCodeQualityCommandHandler.execute(CreateCodeQualityCommandHandler.kt:9)
at net.ntworld.codeCleaner.LocalCommandBus.process(LocalCommandBus.kt:34)
at
net.ntworld.codeCleaner.commandHandler.CreateAnalyzeProcessCommandHandler$handle$1.invoke(CreateAnalyzeProcessCommandHandler.kt:48)
at
net.ntworld.codeCleaner.commandHandler.CreateAnalyzeProcessCommandHandler$handle$1.invoke(CreateAnalyzeProcessCommandHandler.kt:20)
at
net.ntworld.foundation.Infrastructure$DefaultImpls.invoke(Infrastructure.kt:55)
at
net.ntworld.foundation.InfrastructureResolver.invoke(InfrastructureResolver.kt:12)
at
net.ntworld.codeCleaner.commandHandler.CreateAnalyzeProcessCommandHandler.handle(CreateAnalyzeProcessCommandHandler.kt:27)
at
net.ntworld.codeCleaner.commandHandler.CreateAnalyzeProcessCommandHandler.handle(CreateAnalyzeProcessCommandHandler.kt:20)
at
net.ntworld.foundation.cqrs.CommandHandler$DefaultImpls.execute(CommandHandler.kt:10)
at
net.ntworld.codeCleaner.commandHandler.CreateAnalyzeProcessCommandHandler.execute(CreateAnalyzeProcessCommandHandler.kt:20)
at net.ntworld.codeCleaner.LocalCommandBus.process(LocalCommandBus.kt:34)
at
net.ntworld.intellijCodeCleaner.task.AnalyzeTask$run$1.invoke(AnalyzeTask.kt:23)
at
net.ntworld.intellijCodeCleaner.task.AnalyzeTask$run$1.invoke(AnalyzeTask.kt:13)
at
net.ntworld.foundation.Infrastructure$DefaultImpls.invoke(Infrastructure.kt:55)
at
net.ntworld.foundation.InfrastructureWrapper.invoke(InfrastructureWrapper.kt:11)
at net.ntworld.intellijCodeCleaner.task.AnalyzeTask.run(AnalyzeTask.kt:22)
at
com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:888)
at
com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$2(CoreProgressManager.java:163)
at
com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:585)
at
com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:531)
at
com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:59)
at
com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:150)
at
com.intellij.openapi.progress.impl.CoreProgressManager$4.lambda$run$0(CoreProgressManager.java:402)
at
com.intellij.util.ConcurrencyUtil.runUnderThreadName(ConcurrencyUtil.java:221)
at
com.intellij.openapi.progress.impl.CoreProgressManager$4.run(CoreProgressManager.java:402)
at
com.intellij.openapi.application.impl.ApplicationImpl$1.run(ApplicationImpl.java:238)
at
java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at
java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at
java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
Le dim. 5 janv. 2020 à 21:18, Nhat Phan <notifications@github.com> a écrit :
… @subotaii <https://github.com/subotaii> Could you please send me the
sample of sonar-java plugin output. I can't change the contract if I don't
know the output of that plugin.
You can run this command: codeclimate analyze -f json > result.json and
find an item which don't have other_locations key
Thank you in advance!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4?email_source=notifications&email_token=ANCYYQVVOTJWEU47RQ5AFWLQ4I6ARA5CNFSM4KAZHDF2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEID6S2I#issuecomment-570943849>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ANCYYQQBN5FITB5X52WDIYLQ4I6ARANCNFSM4KAZHDFQ>
.
|
Hi @subotaii could you please send me 1 item which doesn't have |
Hey! |
@nhat-phan I see that in result.json file only "engine_name":"checkstyle" have no key other_locations. May be it will helps you |
@nhat-phan |
Nice work with this intellij plugin nhat phan !
When a launch analyze with sonar-java plugin, i got the exception below.
Here my .codeclimate.yml file.
The text was updated successfully, but these errors were encountered: