RE: [sqlalchemy] MetaData.sorted_tables is inconsistant

2015-06-14 Thread Ofir Herzas
bject: Re: [sqlalchemy] MetaData.sorted_tables is inconsistant On 6/14/15 9:06 AM, Ofir Herzas wrote: It seems that MetaData.sorted_tables returns a different result each time. While the results seem to be always correct, it is an odd behavior. A topological sort is non-deterministic. I

Re: [sqlalchemy] MetaData.sorted_tables is inconsistant

2015-06-14 Thread Mike Bayer
On 6/14/15 9:06 AM, Ofir Herzas wrote: It seems that MetaData.sorted_tables returns a different result each time. While the results seem to be always correct, it is an odd behavior. A topological sort is non-deterministic. If two elements A and B have no dependency on each other, they can be

[sqlalchemy] MetaData.sorted_tables is inconsistant

2015-06-14 Thread Ofir Herzas
It seems that MetaData.sorted_tables returns a different result each time. While the results seem to be always correct, it is an odd behavior. I would expect sorted_tables to return the same results every time import sqlalchemy as sa engine = sa.create_engine("", echo=False) meta = sa.MetaData(b