jshiell / checkstyle-idea

CheckStyle plug-in for IntelliJ IDEA
https://plugins.jetbrains.com/plugin/1065-checkstyle-idea
Other
887 stars 161 forks source link

Error "Cannot find packaged artefact" #605

Closed pazoozooCH closed 1 year ago

pazoozooCH commented 1 year ago

With one of the later IntelliJ updates, the plugin stopped working for me and I get an error:

org.infernus.idea.checkstyle.exception.CheckStylePluginException: Cannot find packaged artefact: C:\Users\Martin\AppData\Roaming\JetBrains\IntelliJIdea2022.3\plugins\CheckStyle-IDEA\checkstyle\lib\httpclient5-5.1.3.jar
    at org.infernus.idea.checkstyle.CheckstyleClassLoaderContainer.baseClasspathUrlsForPackagedPlugin(CheckstyleClassLoaderContainer.java:129)
    at org.infernus.idea.checkstyle.CheckstyleClassLoaderContainer.buildClassLoader(CheckstyleClassLoaderContainer.java:102)
    at org.infernus.idea.checkstyle.CheckstyleClassLoaderContainer.<init>(CheckstyleClassLoaderContainer.java:76)
    at org.infernus.idea.checkstyle.CheckstyleProjectService$1.call(CheckstyleProjectService.java:78)
    at org.infernus.idea.checkstyle.CheckstyleProjectService$1.call(CheckstyleProjectService.java:71)
    at org.infernus.idea.checkstyle.CheckstyleProjectService.checkstyleClassLoaderContainer(CheckstyleProjectService.java:134)
    at org.infernus.idea.checkstyle.CheckstyleProjectService.underlyingClassLoader(CheckstyleProjectService.java:123)
    at org.infernus.idea.checkstyle.ui.PropertiesPanel.setConfigurationLocation(PropertiesPanel.java:95)
    at org.infernus.idea.checkstyle.ui.PropertiesDialogue.setConfigurationLocation(PropertiesDialogue.java:104)
    at org.infernus.idea.checkstyle.ui.CheckStyleConfigPanel$EditPropertiesAction.actionPerformed(CheckStyleConfigPanel.java:365)
    at org.infernus.idea.checkstyle.ui.CheckStyleConfigPanel$ToolbarAction.run(CheckStyleConfigPanel.java:381)
    at org.infernus.idea.checkstyle.ui.CheckStyleConfigPanel$ToolbarAction.run(CheckStyleConfigPanel.java:376)
    at com.intellij.ui.ToolbarDecorator$3.doEdit(ToolbarDecorator.java:598)
    at com.intellij.ui.CommonActionsPanel$EditButton.actionPerformed(CommonActionsPanel.java:405)
    at com.intellij.openapi.actionSystem.impl.ActionButton.actionPerformed(ActionButton.java:197)
    at com.intellij.openapi.actionSystem.impl.ActionButton.lambda$performAction$0(ActionButton.java:176)
    at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareWithCallbacks(ActionUtil.java:350)
    at com.intellij.openapi.actionSystem.impl.ActionButton.performAction(ActionButton.java:176)
    at com.intellij.openapi.actionSystem.impl.ActionButton.processMouseEvent(ActionButton.java:465)
    at java.desktop/java.awt.Component.processEvent(Component.java:6413)
    at java.desktop/java.awt.Container.processEvent(Container.java:2266)
    at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5022)
    at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2324)
    at java.desktop/java.awt.Component.dispatchEvent(Component.java:4854)
    at java.desktop/java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4948)
    at java.desktop/java.awt.LightweightDispatcher.processMouseEvent(Container.java:4575)
    at java.desktop/java.awt.LightweightDispatcher.dispatchEvent(Container.java:4516)
    at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2310)
    at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2802)
    at java.desktop/java.awt.Component.dispatchEvent(Component.java:4854)
    at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:781)
    at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:730)
    at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:724)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
    at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
    at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:97)
    at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:754)
    at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:752)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
    at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86)
    at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:751)
    at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:909)
    at com.intellij.ide.IdeEventQueue.dispatchMouseEvent(IdeEventQueue.java:831)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:753)
    at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$5(IdeEventQueue.java:437)
    at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:787)
    at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$6(IdeEventQueue.java:436)
    at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:105)
    at com.intellij.ide.IdeEventQueue.performActivity(IdeEventQueue.java:615)
    at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$7(IdeEventQueue.java:434)
    at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:838)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:480)
    at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:207)
    at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
    at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:121)
    at java.desktop/java.awt.WaitDispatchSupport$2.run(WaitDispatchSupport.java:191)
    at java.desktop/java.awt.WaitDispatchSupport$4.run(WaitDispatchSupport.java:236)
    at java.desktop/java.awt.WaitDispatchSupport$4.run(WaitDispatchSupport.java:234)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
    at java.desktop/java.awt.WaitDispatchSupport.enter(WaitDispatchSupport.java:234)
    at java.desktop/java.awt.Dialog.show(Dialog.java:1080)
    at com.intellij.openapi.ui.impl.DialogWrapperPeerImpl$MyDialog.show(DialogWrapperPeerImpl.java:743)
    at com.intellij.openapi.ui.impl.DialogWrapperPeerImpl.show(DialogWrapperPeerImpl.java:467)
    at com.intellij.openapi.ui.DialogWrapper.doShow(DialogWrapper.java:1676)
    at com.intellij.openapi.ui.DialogWrapper.show(DialogWrapper.java:1634)
    at com.intellij.ide.actions.ShowSettingsUtilImpl.showSettingsDialog(ShowSettingsUtilImpl.java:90)
    at com.intellij.ide.actions.ShowSettingsAction.perform(ShowSettingsAction.java:60)
    at com.intellij.ide.actions.ShowSettingsAction.actionPerformed(ShowSettingsAction.java:47)
    at com.intellij.openapi.actionSystem.ex.ActionUtil.doPerformActionOrShowPopup(ActionUtil.java:327)
    at com.intellij.openapi.keymap.impl.ActionProcessor.performAction(ActionProcessor.java:47)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher$1.performAction(IdeKeyEventDispatcher.java:584)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.lambda$doPerformActionInner$9(IdeKeyEventDispatcher.java:706)
    at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:105)
    at com.intellij.openapi.application.TransactionGuardImpl.performUserActivity(TransactionGuardImpl.java:94)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.lambda$doPerformActionInner$10(IdeKeyEventDispatcher.java:706)
    at com.intellij.openapi.actionSystem.ex.ActionUtil.performDumbAwareWithCallbacks(ActionUtil.java:350)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.doPerformActionInner(IdeKeyEventDispatcher.java:703)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processAction(IdeKeyEventDispatcher.java:647)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processAction(IdeKeyEventDispatcher.java:595)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processActionOrWaitSecondStroke(IdeKeyEventDispatcher.java:478)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.inInitState(IdeKeyEventDispatcher.java:467)
    at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.dispatchKeyEvent(IdeKeyEventDispatcher.java:225)
    at com.intellij.ide.IdeEventQueue.dispatchKeyEvent(IdeEventQueue.java:815)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:750)
    at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$5(IdeEventQueue.java:437)
    at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:787)
    at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$6(IdeEventQueue.java:436)
    at com.intellij.openapi.application.TransactionGuardImpl.performActivity(TransactionGuardImpl.java:113)
    at com.intellij.ide.IdeEventQueue.performActivity(IdeEventQueue.java:615)
    at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$7(IdeEventQueue.java:434)
    at com.intellij.openapi.application.impl.ApplicationImpl.runIntendedWriteActionOnCurrentThread(ApplicationImpl.java:838)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:480)
    at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:207)
    at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:128)
    at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:117)
    at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:113)
    at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:105)
    at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:92)

Non-Bundled Plugins: IdeaVIM (2.1.0) google-java-format (1.15.0.0) CheckStyle-IDEA (5.76.0) tarn.gradle.dependencies (1.6.2)

Kotlin: 223-1.8.0-release-345-IJ8617.56


- Plugin Version: CheckStyle-IDEA v5.76.0

Any ideas?
jshiell commented 1 year ago

Have you tried reinstalling the plugin? Those JARs should all be part out the core plugin package, unless there's something very odd going on.

pazoozooCH commented 1 year ago

Have you tried reinstalling the plugin? Those JARs should all be part out the core plugin package, unless there's something very odd going on.

Ha, thanks for the input, that actually fixed the problem! 🥇

uninstall -> restart -> re-install -> restart - now everything works again!

Thanks for the quick help and for your efforts!

jshiell commented 1 year ago

My pleasure, just glad it worked - no idea how it got into that state, as IDEA manages that download. Very odd ... but good that it's sorted!

pazoozooCH commented 1 year ago

Not sure, sometimes the IntelliJ in-app updates don't work or need to be reverted. In those cases, I would download the latest installer and to a fresh install. Maybe one of those updates messed with the plugins...

pazoozooCH commented 1 year ago

Will try reinstalling a plugin first the next time I have a similar issue. But some other plugins also had issues with the latest IntelliJ updates (like JDK 17 module system issues), so I thought it might be related to something like that...