Hi Tiago,

2011/10/11 Tiago de Paula Peixoto <tiago@skewed.de>
Hi Giuseppe,

On 10/10/2011 11:40 AM, Giuseppe Profiti wrote:
> Hi,
> I encountered a strange problem. While saving a graph from a script, the generated file is mostly )or completely) composed by "NUL" characters. This happens with both dot and xml.gz outputs.
> The script correclty prints the number of edges and vertices. The properties list is also correct and the labels of the vertices are correctly stored in memory andd printed on screen.
> The only output to the file is a huge number of NUL and, in the dot case, some of the edges.
> The error happens after building the graph from a data file (with a custom script) and also after loading (in the interactive console) graphs previously saved in xml.gz format with graph_tool.
> I cannot reproduce the error via interactive console creating a graph with 2 nodes, 1 edge and no properties.
> OS is ubuntu and graph_tool version is 2.2.15-1
> Everything worked just fine until past week.

In order for me to understand what might be going on, you must provide
some sort of example of this problem happening. I've never experienced
anything remotely like this.

Try to reproduce the problem with a short script, and send me the script
so that I may look at it. It would also be useful to take a look at the
corrupt data file itself...

I'll try to create a graph similar to those I'm using, because I cannot share the actual data (NDA and stuff like that).
It seems to be closely related to my graphs: simple graphs (7 nodes, few edges) are not affected.
However, just a simple script like that:

from graph_tool.all import *
g = load_graph('old_graph.xml.gz')

generates the error. 'old_graph.xml.gz' was created few days ago on another machine running graph_tool 2.2.14. The output is attached (I can share that, it contains almost nothing :-) )

I'm trying to pinpoint the type of graph affected by this issue and then I'll share my results with you.

Thanks again,