Open disconnect3d opened 4 years ago
Hi @disconnect3d
Honestly: I don't know. I'd strongly assume because as far as I understand they share the same plattform and Psi as well as the IDE framework is mostly the same (not sure about CLion!). But I haven't tested yet.
I got feedback from users that it works with Android Studio.
Whats the trigger behind your proposal? I'd assume if you are an actual user of those mentioned IDEs, you sure just gave it already a test run, so I assume you are not a user of PyCharm et. al either?
I am an actual user but I haven't given it a try yet. Will check it out in some days and respond if it works ;).
I've tried it for some Python project and got this:
Calling cd /project && /idea-cli-inspector -p profiles_settings.xml
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.codehaus.groovy.reflection.CachedClass (file:/usr/share/groovy/lib/groovy-2.4.16.jar) to method java.lang.Object.finalize()
WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.reflection.CachedClass
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
=
= IntellIJ IDEA Code Analysis Wrapper - v1.7 - @bentolor
=
Use --help or see https://github.com/bentolor/idea-cli-inspector/ for help
#
# Running IDEA IntelliJ Inspection
#
Executing: /srv/idea.latest/bin/idea.sh inspect /project /project/.idea/inspectionProfiles/profiles_settings.xml /project/target/inspection-results -v1
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.intellij.util.ReflectionUtil to field java.awt.event.InvocationEvent.runnable
WARNING: Please consider reporting this to the maintainers of com.intellij.util.ReflectionUtil
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
Starting up IntelliJ IDEA 2020.2.1 (build IC-202.6948.69) ...done.
Opening project...2020-09-23 14:09:06,711 [ 3187] WARN - Container.ComponentManagerImpl - Do not use constructor injection (requestorClass=org.jetbrains.android.compose.AndroidComposeAutoDocumentation)
2020-09-23 14:09:07,072 [ 3548] WARN - tartup.impl.StartupManagerImpl - Activities registered via registerPostStartupActivity must be dumb-aware: org.jetbrains.kotlin.idea.configuration.ui.KotlinConfigurationCheckerComponent$projectOpened$1@7d9aff48
done.
Initializing project...Loaded profile 'profiles_settings' from file '/project/.idea/inspectionProfiles/profiles_settings.xml'
done.
Inspecting with profile 'profiles_settings'
Processing project usages
.........................................................................................................................................2020-09-23 14:09:14,799 [ 11275] WARN - com.intellij.util.xmlb.Binding - no accessors for org.jetbrains.kotlin.idea.highlighter.KotlinDefaultHighlightingSettingsProvider
Analyzing code
.......................................................................................................................................
Done.
2020-09-23 14:09:25,493 [ 21969] ERROR - spection.InspectionsResultUtil - Descriptions are missed for tools: PreviewMustBeTopLevelFunction, PreviewNeedsComposableAnnotation, PreviewDimensionRespectsLimit, PreviewAnnotationInFunctionWithParameters
java.lang.Throwable: Descriptions are missed for tools: PreviewMustBeTopLevelFunction, PreviewNeedsComposableAnnotation, PreviewDimensionRespectsLimit, PreviewAnnotationInFunctionWithParameters
at com.intellij.openapi.diagnostic.Logger.error(Logger.java:143)
at com.intellij.codeInspection.InspectionsResultUtil.describeInspections(InspectionsResultUtil.java:84)
at com.intellij.codeInspection.InspectionApplication.runAnalysis(InspectionApplication.java:375)
at com.intellij.codeInspection.InspectionApplication.runAnalysisOnScope(InspectionApplication.java:343)
at com.intellij.codeInspection.InspectionApplication.run(InspectionApplication.java:284)
at com.intellij.codeInspection.InspectionApplication.execute(InspectionApplication.java:140)
at com.intellij.codeInspection.InspectionApplication.startup(InspectionApplication.java:107)
at com.intellij.codeInspection.InspectionMain.main(InspectionMain.java:99)
at com.intellij.openapi.application.ApplicationStarter.main(ApplicationStarter.java:62)
at com.intellij.idea.ApplicationLoader$startApp$8.run(ApplicationLoader.kt:231)
at java.base/java.util.concurrent.CompletableFuture$UniRun.tryFire(CompletableFuture.java:783)
at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506)
at java.base/java.util.concurrent.CompletableFuture.postFire(CompletableFuture.java:610)
at java.base/java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:1085)
at java.base/java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:478)
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.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:668)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1$1.run(Executors.java:665)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.util.concurrent.Executors$PrivilegedThreadFactory$1.run(Executors.java:665)
at java.base/java.lang.Thread.run(Thread.java:834)
2020-09-23 14:09:25,493 [ 21969] ERROR - spection.InspectionsResultUtil - IntelliJ IDEA 2020.2.1 Build #IC-202.6948.69
2020-09-23 14:09:25,493 [ 21969] ERROR - spection.InspectionsResultUtil - JDK: 11.0.8; VM: OpenJDK 64-Bit Server VM; Vendor: AdoptOpenJDK
2020-09-23 14:09:25,493 [ 21969] ERROR - spection.InspectionsResultUtil - OS: Linux
2020-09-23 14:09:25,494 [ 21970] ERROR - spection.InspectionsResultUtil - Last Action:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Inspecting produced result files in /project/target/inspection-results
#
# Looking for levels : [[WARNING], [ERROR]]
# Ignoring result files : []
# Ignoring source files : []
--- IgnoreFileDuplicateEntry.xml
[WARNING] .gitignore:73 -- <code>*.log</code> pattern is defined more than once #loc
#
# Analysis Result
#
Entries found. Returncode: 1
Thanks for the feedback!
Just to clarify the various warnings:
WARNING: An illegal reflective access operation has occurred
This is a plain groovy issue with an interop issue with the JVM. Ecpect it as "normal" until Groovy itself solves it.
2020-09-23 14:09:25,493 [ 21969] ERROR - spection.InspectionsResultUtil - Descriptions are missed for tools: PreviewMustBeTopLevelFunction, PreviewNeedsComposableAnnotation, PreviewDimensionRespectsLimit, PreviewAnnotationInFunctionWithParameters
java.lang.Throwable: Descriptions are missed for tools: PreviewMustBeTopLevelFunction, PreviewNeedsComposableAnnotation, PreviewDimensionRespectsLimit, PreviewAnnotationInFunctionWithParameters
These are typicals issue with inspections: They tend to work in the UI-mode but some fail sporadically in headless mode. They might reveal bugs in the inspection code and you can report them to Jetbrains.
You should have a look on those, because they might inhibit the successful run of other inspections. If in doubt, comment them out.
Hey,
quick question: does this tool run with other Jetbrain IDEs like PyCharm, RubyMine or CLion?
If so, could you include a sentence that it does so in the first paragraph of the project README?
Thanks :)