You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm having problem with opening any GUI application in a running container. In short, I always get similar "cannot open display" errors from different applications.
Generating result report...
Traceback (most recent call last):
File "/catkin_ws/devel/lib/kalibr/kalibr_calibrate_cameras", line 15, in <module>
exec(compile(fh.read(), python_script, 'exec'), context)
File "/catkin_ws/src/kalibr/aslam_offline_calibration/kalibr/python/kalibr_calibrate_cameras", line 465, in <module>
main()
File "/catkin_ws/src/kalibr/aslam_offline_calibration/kalibr/python/kalibr_calibrate_cameras", line 429, in main
kcc.generateReport(calibrator, reportFile, showOnScreen=not parsed.dontShowReport, graph=G, removedOutlierCorners=removedOutlierCorners);
File "/catkin_ws/src/kalibr/aslam_offline_calibration/kalibr/python/kalibr_camera_calibration/CameraUtils.py", line 428, in generateReport
fig = pl.figure(offset)
File "/usr/lib/python3/dist-packages/matplotlib/pyplot.py", line 539, in figure
figManager = new_figure_manager(num, figsize=figsize,
File "/usr/lib/python3/dist-packages/matplotlib/backend_bases.py", line 3259, in new_figure_manager
return cls.new_figure_manager_given_figure(num, fig)
File "/usr/lib/python3/dist-packages/matplotlib/backends/_backend_tk.py", line 950, in new_figure_manager_given_figure
window = tk.Tk(className="matplotlib")
File "/usr/lib/python3.8/tkinter/__init__.py", line 2270, in __init__
self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: couldn't connect to display ":1"
In addition, even if I set -dont-show-report as a parameter, I always get the same error. I have also tried 'xeyes' as a test. Here I also get the same error regarding Can't open display: :1. I am beginning to despair. Do you have a solution?
The text was updated successfully, but these errors were encountered:
I'm having problem with opening any GUI application in a running container. In short, I always get similar "cannot open display" errors from different applications.
Platform
Host : Ubuntu 22.04
Docker : Docker Desktop 4.36.0
Image : kalibr (Ubuntu 20.04 and ROS Noetic based image)
who
--> give us :1export DISPLAY=:1
Run Command
I've tried also:
xhost +local:root, xhost +local:docker, even xhost +
before running container--privileged
--runtime=runc
DISPLAY=127.0.1.1:1
(i.e. my host IP)DISPLAY=unix$DISPLAY
Extra Info
Some env vars in the container: HOSTNAME=docker-desktop DISPLAY=:1 QT_X11_NO_MITSHM=1
Inside the docker container:
Everytime i ran into this error:
In addition, even if I set
-dont-show-report
as a parameter, I always get the same error. I have also tried 'xeyes' as a test. Here I also get the same error regardingCan't open display: :1
. I am beginning to despair. Do you have a solution?The text was updated successfully, but these errors were encountered: