general "did not match C++ signature" error


Graph-tool was manually compiled on a local cluster (based on RedHat) by a
network admin. The python command
import graph_tool
works fine, but almost every other command results in an error related to
"did not match C++ signature":
For example,
(attached) results in:
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/epd/lib/python2.7/site-packages/graph_tool/",
line 2702, in load_graph
    g.load(file_name, fmt, ignore_vp, ignore_ep, ignore_gp)
  File "/usr/local/epd/lib/python2.7/site-packages/graph_tool/",
line 2320, in load
    ignore_ep, ignore_gp)
Boost.Python.ArgumentError: Python argument types in
    GraphInterface.read_from_file(GraphInterface, str, NoneType, str, list,
list, list)
did not match C++ signature:
    read_from_file(graph_tool::GraphInterface {lvalue},
std::__cxx11::basic_string<char, std::char_traits&lt;char>,
std::allocator<char> >, boost::python::api::object,
std::__cxx11::basic_string<char, std::char_traits&lt;char>,
std::allocator<char> >, boost::python::list, boost::python::list,

Following some other posts in the mailing list, I've applied the ldd command
/usr/local/epd/lib/python2.7/site-packages/graph_tool/ => (0x00007ffff7ffe000) => /usr/lib64/
(0x00007ffff5c46000) => /usr/lib64/
(0x00007ffff59f5000) => /usr/lib64/
(0x00007ffff56df000) => /usr/lib64/
(0x00007ffff54d4000) =>
(0x00007ffff52af000) => /lib64/ (0x00007ffff5087000) =>
(0x00007ffff4cf8000) => /lib64/ (0x00007ffff4a74000) => /lib64/ (0x00007ffff46e0000) =>
(0x00007ffff44c9000) => /lib64/ (0x00007ffff42b8000) => /usr/local/epd/lib/ (0x00007ffff409a000) => /lib64/ (0x00007ffff3e91000) => /lib64/ (0x00007ffff3c74000) => /usr/lib64/ (0x00007ffff38ce000) => /usr/lib64/ (0x00007ffff2788000) => /usr/lib64/ (0x00007ffff23f2000) => /usr/lib64/ (0x00007ffff20a0000) => /usr/lib64/
(0x00007ffff1e96000) => /usr/lib64/
(0x00007ffff1c74000) => /usr/lib64/
(0x00007ffff1a6d000) => /usr/lib64/
(0x00007ffff1869000) => /usr/lib64/ (0x00007ffff161c000) => /usr/lib64/ (0x00007ffff13c1000)
  /lib64/ (0x0000003f14800000) => /lib64/ (0x00007ffff11bc000) => /lib64/ (0x00007ffff0fb9000)


Ni !

The import working means that Python can find the Python component of graph

The error you get has to do with boost Python not finding, for a call
internal to the Python component, a corresponding function in the C++
component that matches it's argument types.

Thus, this happens if any of the pieces involved do not match. A common
cause is version mismatch.

Ldd is useful to check some of those: the versions of libraries linked to
the C++ component.

In your led output I see => /usr/lib64/ (0x00007ffff38ce000)

Thus it seems to be the case that the package got compiled against Python
2.6, yet got installed for Python 2.7 .



attachment.html (6.42 KB)

Short of a solution there are two posts with similar problems online:

The issue seems to normally revolve around using different versions of Python or packages when compiling. Maybe ask your network admin to recompile paying particular attention to that and see if it fixes it?

Best wishes,


attachment.html (11.5 KB)


This is indeed strange, as the library is installed to

but compiled against: => /usr/lib64/ (0x00007ffff38ce000)

How do I specify which libpython to use?

This should be detected automatically when ./configure is run. The specific
python interpreter can be overridden by setting the PYTHON environment
variable to ./configure.

But your symptom can also be caused by your custom python library (which
seems to be installed in the nonstandard path /usr/local/epd) not being set
in the linker's path. This could be fixed by doing something like: export

But these are just some guesses, since you gave us very little information.
Ideally, you would give us all parameters you passed to ./configure during
compilation, as well as the contents to config.log.


Dear Tiago,

Thanks for the tip.
Please see the attached log file. As far as I know, there were no flags
added, but perhaps the epd setup script (setup.csh) was first initialized.
The EPD python is the python interpreter I would like to use.


attachment.html (5.92 KB)

Try passing


to configure while compiling. Also, do not forget to set LD_LIBRARY_PATH as
I said, before trying to import the library.


It seems there is no LDFLAGS option in the configure. I'm using graph-tool


attachment.html (12.3 KB)

It is not an option, it is an environment variable. What you should do is

    ./configure LDFLAGS="-L/usr/local/epd/lib/"

Please take a look at the installation instructions at:

(This is WIP and will substitute the current instructions in the website)