Creating Display() fails with "Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'No protocol specified\n"

Bug #1432889 reported by Christopher Lee
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
python-xlib (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

After a recent dist-upgrade on vivid the following code now raises an exception:

 $ python3 -c "from Xlib import display; display.Display()"

Error:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/lib/python3/dist-packages/Xlib/display.py", line 80, in __init__
    self.display = _BaseDisplay(display)
  File "/usr/lib/python3/dist-packages/Xlib/display.py", line 62, in __init__
    display.Display.__init__(*(self, ) + args, **keys)
  File "/usr/lib/python3/dist-packages/Xlib/protocol/display.py", line 129, in __init__
    raise error.DisplayConnectionError(self.display_name, r.reason)
Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'No protocol specified\n'

This code was working fine before the dist-upgrade.

Package version is: 0.14+20091101-1ubuntu2 what's odd is that this hasn't appeared to have changed since the dist-upgrade.

This issue is causing all autopilot tests run on the desktop to fail (see: https://bugs.launchpad.net/autopilot/+bug/1432700)

description: updated
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python-xlib - 0.14+20091101-1ubuntu3

---------------
python-xlib (0.14+20091101-1ubuntu3) vivid; urgency=medium

  * debian/patches/lp1432889.patch: properly decode the xauthority file
    into strings instead of byte arrays in Xlib/xauth.py. (LP: #1432889)
 -- Marc Deslauriers <email address hidden> Tue, 17 Mar 2015 11:17:02 -0400

Changed in python-xlib (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.