Community
Participate
Working Groups
When running SWT on Linux, for exampele with DISPLAY not set or any issue with DISPLAY, and Display.createDisplay() will tell you on line 905 "No more handles". This error is quite confusing, and as far as I know, a fail of gtk_init_check on Linux/GTK is never related to handles. So the error message is always inaccurate and confusing. Since a "No more handle" error is generally annoying to debug, it would be convenient to add in the case this error occur some diagnostic to help in debugging (for instance, checking DISPLAY property and checking the ability to consume an X server on the specified DISPLAY). As I am not expert of Gtk, I don't know whether it is possible to get more insight on this issue when it appears. If possible, it would be convenient to have Gtk telling why it fails to init.
(In reply to Mickael Istria from comment #0) > When running SWT on Linux, for exampele with DISPLAY not set or any issue > with DISPLAY, and Display.createDisplay() will tell you on line 905 "No more > handles". > > This error is quite confusing, and as far as I know, a fail of > gtk_init_check on Linux/GTK is never related to handles. So the error > message is always inaccurate and confusing. > Since a "No more handle" error is generally annoying to debug, it would be > convenient to add in the case this error occur some diagnostic to help in > debugging (for instance, checking DISPLAY property and checking the ability > to consume an X server on the specified DISPLAY). As I am not expert of Gtk, > I don't know whether it is possible to get more insight on this issue when > it appears. If possible, it would be convenient to have Gtk telling why it > fails to init. In what scenario do you normally run into this issue? I noticed on Wayland this issue doesn't seem to occur when I do: export DISPLAY=:5 ./eclipse It'll complaint a bit, but eclipse fires up. Haven't tested on X11 yet.
When I open this bug a while ago, I believe the issue was that on some CI machine, I saw this message and it took me a lot of time to understand that a X server was missing.
"No more handles" is general inability to create native resource. Changing it is out of scope but it makes sense to improve in given cases when we can give better message. This should be handled in their own separate bugs with clear goals.
I imagine the message could be different if some handle could already be created or not: if at least 1 handle was successfully created: `Could not acquire extra system resource handle. That may mean that application got disconnected from windowing System, or that the current application is suffering from a resource handle leak and fails to dispose some handles.` if 0 handle was successfully created: `Could not acquire any system handle. That usually means this application could not connect to the windowing system."