0

I'm running graph-tool on Debian Jessie amd64. This server does not have X installed, nor do I wish to install it. Whenever I attempt to import * (per the quick start documentation), the following happens:

Python 2.7.9 (default, Mar  1 2015, 12:57:24)
[GCC 4.9.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from graph_tool.all import *
Unable to init server: Could not connect: Connection refused
Unable to init server: Could not connect: Connection refused
>>>

Attempting an strace on a test script is cumbersome, since there are a large number of libraries loaded when the above happens, but from spending a couple hours trawling through the output, I think it may be X or gdk-related. I'm hoping someone here knows what's causing this, and what I can do to prevent these seemingly cosmetic warnings from occurring, aside from redirecting STDERR to /dev/null.

Thanks.

John Jensen
  • 422
  • 4
  • 20

1 Answers1

1

This happens because it attempts to import Gtk, which tries to open an X11 connection.

Tiago Peixoto
  • 5,149
  • 2
  • 28
  • 28