Uploaded image for project: 'Cayenne'
  1. Cayenne
  2. CAY-2603

NPE reloading project in the model

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 4.1.RC1
    • Fix Version/s: 4.1.RC1, 4.2.M1
    • Component/s: Modeler
    • Labels:
      None
    • Environment:
      4.1.B3-SNAPSHOT, Jul 19 2019 build

      Description

      1. I have a project open in the Modeler, class generation view.
      2. From the terminal I did "git checkout -f" to undo my local changes. This removed one of the new entities
      3. The modeler correctly suggested me to reload the project, which I did.

      Result: error dialog with the following exception:


      CayenneModeler Info
      Version: 4.1.B3-SNAPSHOT
      Build Date: Jul 19 2019 11:42:53
      Exception:
      =================================
      java.lang.NullPointerException
      at org.apache.cayenne.modeler.editor.cgen.CodeGeneratorControllerBase.getSelectedEntities(CodeGeneratorControllerBase.java:263)
      at org.apache.cayenne.modeler.editor.cgen.CodeGeneratorControllerBase.updateEntities(CodeGeneratorControllerBase.java:405)
      at org.apache.cayenne.modeler.editor.cgen.CodeGeneratorControllerBase.updateSelectedEntities(CodeGeneratorControllerBase.java:392)
      at org.apache.cayenne.modeler.editor.cgen.ClassesTabController.classSelectedAction(ClassesTabController.java:117)
      at org.apache.cayenne.modeler.editor.cgen.CodeGeneratorController.generatorSelectedAction(CodeGeneratorController.java:135)
      at org.apache.cayenne.modeler.editor.cgen.CodeGeneratorController.initBindings(CodeGeneratorController.java:123)
      at org.apache.cayenne.modeler.editor.cgen.CodeGeneratorController.<init>(CodeGeneratorController.java:69)
      at org.apache.cayenne.modeler.editor.DataMapTabbedView.initView(DataMapTabbedView.java:66)
      at org.apache.cayenne.modeler.editor.DataMapTabbedView.<init>(DataMapTabbedView.java:50)
      at org.apache.cayenne.modeler.editor.EditorView.initView(EditorView.java:225)
      at org.apache.cayenne.modeler.editor.EditorView.<init>(EditorView.java:165)
      at org.apache.cayenne.modeler.CayenneModelerController.projectOpenedAction(CayenneModelerController.java:215)
      at org.apache.cayenne.modeler.action.OpenProjectAction.openProjectResourse(OpenProjectAction.java:184)
      at org.apache.cayenne.modeler.action.OpenProjectAction.openProject(OpenProjectAction.java:175)
      at org.apache.cayenne.modeler.ProjectFileChangeTracker$1.run(ProjectFileChangeTracker.java:113)
      at java.desktop/java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:313)
      at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:770)
      at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
      at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
      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:740)
      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:
              Unassigned
              Reporter:
              andrus Andrus Adamchik
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: