On Tue, Sep 29, 2009 at 09:36:57AM +0200, Kjell Magne Fauske wrote: > Thank you Nicolas for chasing down this bug.
Take it as a self-inflicted punishment for not reading the manual in the first place :-) > I have made the changes > you suggested: > http://code.google.com/p/dot2tex/source/detail?r=249 > I have to test it some more, but could you try the latest version of > dot2tex.py from trunk to verify that it fixes your problem? > http://dot2tex.googlecode.com/svn-history/r249/trunk/dot2tex/dot2tex.py It does! Thanks! Just wondering about the new version: + try: + data = stdout.read() + finally: + stdout.close() + + try: + error_data = stderr.read() + if error_data: + log.debug('Graphviz STDERR %s', error_data) + finally: + stderr.close() Could closing stdout early prevent from reading all the information from stderr? Also, in case of an exception in the first block, stderr is not closed, right? Should there be a single try ... finally close? Well, again, I am a novice here, and there must be a standard python mantra for this use case. Googling around, I only found so far: http://www.gossamer-threads.com/lists/python/dev/754673 > I will look into this, It is probably because of the way the graph > is represented internally. The parser and data structure is not very > elegant. A node can appear multiple times in a graph structure. So > instead of keeping track of where every node is in the structure I > just append a node statement at the end of the graph when I want to > modify attributes. Thanks for the info! Nicolas -- Nicolas M. ThiƩry "Isil" <nthi...@users.sf.net> http://Nicolas.Thiery.name/ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "sage-combinat-devel" group. To post to this group, send email to sage-combinat-devel@googlegroups.com To unsubscribe from this group, send email to sage-combinat-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-combinat-devel?hl=en -~----------~----~----~----~------~----~------~--~---