jamesscottbrown / pyyed

A simple Python library to export networks to yEd
BSD 3-Clause "New" or "Revised" License
82 stars 38 forks source link

Python3 part 2 #5

Closed marco-m closed 6 years ago

marco-m commented 6 years ago

This is the absolute minimum to be able to use pyyed both with Python2.7 and Python3.

There are still problems when running demo.py with Python3, for example node "foo2" doesn't get underlined and the shape stays rectangular. On the other hand it is already useable.

Since there are no tests I cannot be sure I didn't introduce regressions for Python2, I would suggest to generate a few graphs with your master branch and compare the results against this branch.

Note that I had to move file pyyed.py to init.py, since the trick in init.py to import itself didn't work with Python3.

Note also that I had to make minimal changes to pyyed.py in order to return a string and not a byte-string with Python3, to see the changes you have to look at the individual commits in this PR, since the overview diff in this page just bundles everything together.

jamesscottbrown commented 6 years ago

Thanks - this is very helpful.

I've fixed the bug that was causing "foo2" to loose its custom formatting in 51b778d.