Closed Quasar985 closed 1 week ago
Another observation I made was that if you spam it enough times, there comes a point where the schema view starts to lag while trying to load (mostly when you got to memory limits) and to the point that it doesn't really load properly
Still managed to get:
java.lang.NullPointerException: Cannot read field "children" because the return value of "javafx.scene.Node.getParent()" is null javafx.graphics/javafx.scene.Parent$2.onChanged(Parent.java:340) javafx.base/com.sun.javafx.collections.TrackableObservableList.lambda$new$0(TrackableObservableList.java:44) javafx.base/com.sun.javafx.collections.ListListenerHelper$Generic.fireValueChangedEvent(ListListenerHelper.java:327) javafx.base/com.sun.javafx.collections.ListListenerHelper.fireValueChangedEvent(ListListenerHelper.java:71) javafx.base/javafx.collections.ObservableListBase.fireChange(ObservableListBase.java:246) javafx.base/javafx.collections.ListChangeBuilder.commit(ListChangeBuilder.java:482) javafx.base/javafx.collections.ListChangeBuilder.endChange(ListChangeBuilder.java:541) javafx.base/javafx.collections.ObservableListBase.endChange(ObservableListBase.java:210) javafx.base/javafx.collections.ModifiableObservableListBase.addAll(ModifiableObservableListBase.java:117) javafx.base/com.sun.javafx.collections.VetoableListDecorator.addAll(VetoableListDecorator.java:241) javafx.base/com.sun.javafx.collections.VetoableListDecorator.addAll(VetoableListDecorator.java:105) javafx.graphics/javafx.scene.layout.VBox.<init>(VBox.java:240) au.gov.asd.tac.constellation.views.schemaview.providers.VertexTypeNodeProvider.addFilter(VertexTypeNodeProvider.java:216) au.gov.asd.tac.constellation.views.schemaview.providers.VertexTypeNodeProvider.setContent(VertexTypeNodeProvider.java:272) au.gov.asd.tac.constellation.views.schemaview.SchemaViewPane.lambda$populate$0(SchemaViewPane.java:58)
Was following the reproducer you outlined (i.e. spamming Schema View open and close very quickly)
99% sure I've fixed with the newest commit. I tested with an auto-clicker that is able to open and close the schema view many times a second. This error rarely showed up to begin with, but I reckon I've got it fixed.
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
50.0% Duplication on New Code
Prerequisites
[x] Reviewed the checklist
[x] Reviewed feedback from the "Sonar Cloud" bot. Note that you have to wait for the "CI / Unit Tests") to complete first. Failed Unit tests can be debugged by adding the label "verbose logging" to the GitHub PR.
Description of the Change
Added synchronize to functions so that rapid closing and opening of schema view doesn't throw errors.
Alternate Designs
N/A
Why Should This Be In Core?
N/A
Benefits
Bug fixes
Possible Drawbacks
None
Verification Process
Applicable Issues
https://github.com/constellation-app/constellation/issues/2144