Linux/CentOS: TigerVNC Server: Dialogs are all black on 'Take Screenshot'

Asked by Mat

SikuliIDE 2.0.4
OS: CentOS 7 running on TigerVNC

I am testing an application, and everything works fine until there is a dialog box (ie: to browse to a file) or pop-up message (ie: error message with OK button). When attempting to take a screenshot via Sikuli, the main application remains visible, but the dialog/popup is all black. Same occurs when running the scripts, and the image cannot be found.

In the past there was a "work around" when if we dragged the blackened window over a couple of pixles it would appear, and we could continue, but that doesn't seem to be working any more.

I know there must be something that can be done for this, and I imagine this has been asked a million times, but I cannot seem to find the answer anywhere.

Any help would be greatly appreciated, as I am currently at a full stop on this...

Thanks!

Question information

Language:
English Edit question
Status:
Answered
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
RaiMan (raimund-hocke) said :
#1

Surely nothing, where SikuliX can help or is the reason for this behavior.

Must be a problem of the GUI manager setup in Linux/TigerVNC.

--- In the past there was a "work around" when if we dragged the blackened window over a couple of pixles it would appear, and we could continue, but that doesn't seem to be working any more.

This looks like the GUI in this case only makes the dialog element finally visible, when the mouse is clicked inside.

Revision history for this message
Mat (mathieu-cormier) said :
#2

I will look more into the Linux/TigerVNC setup, but the application I am testing runs fine stand-alone. This issue only presents itself when running it through Sikuli.

Are there any logs I can verify to see if I am getting errors? Any other troubleshooting steps you can suggest?

Thank you for the help!

Revision history for this message
RaiMan (raimund-hocke) said :
#3

--- runs fine stand-alone
--- issues when running it through Sikuli

not clear what this means. What is the difference?

SikuliX does not "run" any application - it does not know anything about applications.

It only acts on the screen (seen as a rectangle of pixels) and issues keyboard and mouse actions.

Revision history for this message
Mat (mathieu-cormier) said :
#4

Bad wording on my part.

- The application we are testing works without any issues when we run it on VNC, manually.

- The issues only appear, while running on VNC, when:
     - We try to take a screenshot using Sikuli
     - We run our Sikuli test scripts (Sikuli scripts "Launch" our application and run tests)

Revision history for this message
RaiMan (raimund-hocke) said :
#5

To understand right:
- you have a CentOS machine where you run a VNC server
- you have another machine where you run a VNC Viewer (what system)

Where are the SikuliX tests running?

Revision history for this message
Mat (mathieu-cormier) said :
#6

I am running a CentOS 7 machine that connects to a VLAB (also running CentOS 7). From the VLAB, we connect to a VNC Server (Also running on CentOS 7) to run the application and Sikuli. So both the application and Sikuli are on the VNC machine.

Revision history for this message
RaiMan (raimund-hocke) said :
#7

So you have
UserSystem <-> VLAB <-> VNCServerSystem

- you see the screen of the VNCServerSystem on the UserSystem (via a VNCViewer or similar)
- you use mouse and keyboard on the UserSystem to act on the VNCServerSystem (start/use SikuliX and/or applications)

--- When attempting to take a screenshot via Sikuli, the main application remains visible, but the dialog/popup is all black
This means you have the SikuliX IDE running on the VNCServerSystem and try to make a screenshot of some element you see in the viewer.

I understand: you see a popup of the application (non-black), but when you click the capture button (or use the shortcut), the dialog area is black in the screenshot overlay (where you cut out the shot).

I remember, that this was a problem in the past on Linux systems, that could be solved by using another GUI manager.
But sorry: I do not remember details.

... and sorry, your environment is far beyond my knowledge and experience.

It might help, to try with Java 11 (has many improvements targeting screen handling).

Revision history for this message
Mat (mathieu-cormier) said :
#8

All of the above is correct.

Thanks for your help anyways, I will keep troubleshooting and trying different things. If I figure it out I will surely come back to let you know!

Thanks again :)

Revision history for this message
RaiMan (raimund-hocke) said :
#9

All the best and thank YOU.

I will implement a setup with TigerVNC, to get more insight.

Can you help with this problem?

Provide an answer of your own, or ask Mat for more information if necessary.

To post a message you must log in.