Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: Cannot invoke "javafx.scene.Node.getScene()" because "n" is null #1363

Open
XMRZombie opened this issue Oct 30, 2024 · 3 comments
Open
Labels
is:bug Something isn't working as expected

Comments

@XMRZombie
Copy link
Contributor

This happens when a UI component is not properly initialized or added to the scene graph before layout operations occur.

[JavaFX Application Thread] ERROR haveno.common.setup.CommonSetup: Uncaught Exception from thread JavaFX Application Thread, error=Cannot invoke "javafx.scene.Node.getScene()" because "n" is null
 java.lang.NullPointerException: Cannot invoke "javafx.scene.Node.getScene()" because "n" is null
	at javafx.graphics/javafx.scene.layout.Region.getSnapScaleX(Region.java:264)
	at javafx.graphics/javafx.scene.layout.Region.layoutInArea(Region.java:2534)
	at javafx.controls/javafx.scene.control.SkinBase.layoutInArea(SkinBase.java:965)
	at javafx.controls/javafx.scene.control.SkinBase.layoutInArea(SkinBase.java:850)
	at javafx.controls/javafx.scene.control.skin.TableViewSkinBase.layoutChildren(TableViewSkinBase.java:458)
	at javafx.controls/javafx.scene.control.Control.layoutChildren(Control.java:612)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1208)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Parent.layout(Parent.java:1215)
	at javafx.graphics/javafx.scene.Scene.doLayoutPass(Scene.java:594)
	at javafx.graphics/javafx.scene.Scene$ScenePulseListener.pulse(Scene.java:2600)
	at javafx.graphics/com.sun.javafx.tk.Toolkit.lambda$runPulse$2(Toolkit.java:401)
	at java.base/java.security.AccessController.doPrivileged(AccessController.java:400)
	at javafx.graphics/com.sun.javafx.tk.Toolkit.runPulse(Toolkit.java:400)
	at javafx.graphics/com.sun.javafx.tk.Toolkit.firePulse(Toolkit.java:430)
	at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:592)
	at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.pulse(QuantumToolkit.java:572)
	at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.pulseFromQueue(QuantumToolkit.java:565)
	at javafx.graphics/com.sun.javafx.tk.quantum.QuantumToolkit.lambda$runToolkit$11(QuantumToolkit.java:352)
	at javafx.graphics/com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
	at javafx.graphics/com.sun.glass.ui.gtk.GtkApplication._runLoop(Native Method)
	at javafx.graphics/com.sun.glass.ui.gtk.GtkApplication.lambda$runLoop$10(GtkApplication.java:263)
	at java.base/java.lang.Thread.run(Thread.java:1583)

@XMRZombie XMRZombie changed the title error=Cannot invoke "javafx.scene.Node.getScene()" because "n" is null Cannot invoke "javafx.scene.Node.getScene()" because "n" is null Oct 30, 2024
@XMRZombie XMRZombie changed the title Cannot invoke "javafx.scene.Node.getScene()" because "n" is null ERROR: Cannot invoke "javafx.scene.Node.getScene()" because "n" is null Oct 30, 2024
@woodser
Copy link
Contributor

woodser commented Oct 30, 2024

This error is often the result of building and running the application, and then rebuilding while the application is still running, so the current runtime becomes outdated, in case you were doing development work which could have caused it?

Otherwise the error is rare and random and I haven't been able to track down its root cause, without a useful link in the stack trace.

@XMRZombie
Copy link
Contributor Author

I built haveno from source and always making sure to shutdown the client before doing $ make clean

@woodser woodser added the is:bug Something isn't working as expected label Oct 31, 2024
@woodser
Copy link
Contributor

woodser commented Oct 31, 2024

I think we're stuck without a way to reproduce it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
is:bug Something isn't working as expected
Projects
None yet
Development

No branches or pull requests

2 participants