dkandalov / live-plugin

IntelliJ plugin for writing IntelliJ plugins at runtime ⚡️
https://plugins.jetbrains.com/plugin/7282
Apache License 2.0
858 stars 67 forks source link

Fix exception thrown at startup in WebStorm due to missing icon #101

Closed russelldavis closed 5 years ago

russelldavis commented 5 years ago

The exception looked like this:

Caused by: java.lang.RuntimeException: Can't find icon in '/org/jetbrains/kotlin/idea/icons/kotlin_file.png' near class liveplugin.IdeUtil$KotlinScriptFileType$Companion$kotlinScriptIcon$2
    at com.intellij.openapi.util.IconLoader.findIcon(IconLoader.java:191)
    at com.intellij.openapi.util.IconLoader.findIcon(IconLoader.java:176)
    at com.intellij.openapi.util.IconLoader.findIcon(IconLoader.java:171)
    at com.intellij.openapi.util.IconLoader.findIcon(IconLoader.java:138)
    at liveplugin.IdeUtil$KotlinScriptFileType$Companion$kotlinScriptIcon$2.invoke(IdeUtil.kt:247)
    at liveplugin.IdeUtil$KotlinScriptFileType$Companion$kotlinScriptIcon$2.invoke(IdeUtil.kt:243)
    at kotlin.SynchronizedLazyImpl.getValue(Lazy.kt:131)
    at liveplugin.IdeUtil$KotlinScriptFileType$Companion.getKotlinScriptIcon(IdeUtil.kt)
    at liveplugin.IdeUtil$KotlinScriptFileType$Companion.access$getKotlinScriptIcon$p(IdeUtil.kt:243)
    at liveplugin.IdeUtil$KotlinScriptFileType.getIcon(IdeUtil.kt:238)
    at liveplugin.toolwindow.popup.NewFileAction.<init>(NewFileAction.java:36)
    at liveplugin.toolwindow.popup.NewKotlinFileAction.<init>(new-element-actions.kt:21)
    ... 22 more

(also reported at https://github.com/dkandalov/live-plugin/issues/81#issuecomment-388404074)

dkandalov commented 5 years ago

Thanks a lot!