Uploaded image for project: 'SonarLint For IntelliJ'
  1. SonarLint For IntelliJ
  2. SLI-375

NullPointerException can be thrown when flushing issues to disk on project close

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.5
    • Component/s: None
    • Labels:
      None

      Description

      java.lang.NullPointerException
      	at org.sonarsource.sonarlint.core.client.api.connected.objectstore.HashingPathMapper.toHash(HashingPathMapper.java:65)
      	at org.sonarsource.sonarlint.core.client.api.connected.objectstore.HashingPathMapper.apply(HashingPathMapper.java:53)
      	at org.sonarsource.sonarlint.core.client.api.connected.objectstore.HashingPathMapper.apply(HashingPathMapper.java:30)
      	at org.sonarlint.intellij.issue.persistence.IndexedObjectStore.write(IndexedObjectStore.java:109)
      	at org.sonarlint.intellij.issue.persistence.IssuePersistence.save(IssuePersistence.java:74)
      	at org.sonarlint.intellij.issue.persistence.LiveIssueCache.lambda$flushAll$0(LiveIssueCache.java:105)
      	at java.base/java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
      	at org.sonarlint.intellij.issue.persistence.LiveIssueCache.flushAll(LiveIssueCache.java:101)
      	at org.sonarlint.intellij.issue.persistence.LiveIssueCache.projectClosed(LiveIssueCache.java:118)
      	at com.intellij.openapi.project.impl.ProjectManagerImpl.fireProjectClosed(ProjectManagerImpl.java:878)
      	at com.intellij.openapi.project.impl.ProjectManagerImpl.lambda$closeProject$17(ProjectManagerImpl.java:757)
      	at com.intellij.openapi.application.impl.ApplicationImpl.runWriteAction(ApplicationImpl.java:885)
      	at com.intellij.openapi.project.impl.ProjectManagerImpl.closeProject(ProjectManagerImpl.java:750)
      	at com.intellij.openapi.project.impl.ProjectManagerImpl.closeAndDispose(ProjectManagerImpl.java:781)
      	at com.intellij.openapi.wm.impl.CloseProjectWindowHelper.closeProjectAndShowWelcomeFrameIfNoProjectOpened(CloseProjectWindowHelper.kt:44)
      	at com.intellij.openapi.wm.impl.CloseProjectWindowHelper.windowClosing(CloseProjectWindowHelper.kt:32)
      	at com.intellij.openapi.wm.impl.ProjectFrameHelper$2.windowClosing(ProjectFrameHelper.java:282)
      	at java.desktop/java.awt.AWTEventMulticaster.windowClosing(AWTEventMulticaster.java:357)
      	at java.desktop/java.awt.AWTEventMulticaster.windowClosing(AWTEventMulticaster.java:357)
      	at java.desktop/java.awt.Window.processWindowEvent(Window.java:2079)
      	at java.desktop/javax.swing.JFrame.processWindowEvent(JFrame.java:298)
      	at java.desktop/java.awt.Window.processEvent(Window.java:2038)
      	at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5026)
      	at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321)
      	at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2773)
      	at java.desktop/java.awt.Component.dispatchEvent(Component.java:4858)
      	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:778)
      	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:727)
      	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
      	at java.base/java.security.AccessController.doPrivileged(Native Method)
      	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
      	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95)
      	at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:751)
      	at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:749)
      	at java.base/java.security.AccessController.doPrivileged(Native Method)
      	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
      	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:748)
      	at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:908)
      	at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:781)
      	at com.intellij.ide.IdeEventQueue.lambda$dispatchEvent$8(IdeEventQueue.java:424)
      	at com.intellij.openapi.progress.impl.CoreProgressManager.computePrioritized(CoreProgressManager.java:698)
      	at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:423)
      	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
      	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
      	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
      	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
      	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
      	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
      

        Attachments

          Activity

            People

            Assignee:
            julien.henry Julien Henry
            Reporter:
            jeanbaptiste.lievremont Jean-Baptiste Lievremont
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: