[sqlalchemy] Re: composite primary key problem

2009-08-25 Thread Martijn Faassen
Hey, Michael Bayer wrote: the program works for me, I get: That's interesting. I've tested the script with Python 2.4, Python 2.5, and Python 2.6, with SQLAlchemy 0.5.5 and trunk. sqlite version is 3.4.2. I get the assertion error each time. The output I get when echo is True (on SA

[sqlalchemy] Re: composite primary key problem

2009-08-25 Thread Martijn Faassen
Hey, I now also tested the program with sqlite3 3.6.10: same problem. pysqlite2.5.5 is in use. Regards, Martijn --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups sqlalchemy group. To post to this group, send

[sqlalchemy] Re: composite primary key problem

2009-08-25 Thread Martijn Faassen
Hi there, I'm looking at the remove() method in sqlalchemy.orm.identify.WeakInstanceDict, as this is where the assertion error is raised. In the 'self' dictionary there is indeed an sqlalchemy.orm.state.InstanceState object with under the key (it's the only entry in the dictionary), but

[sqlalchemy] Re: composite primary key problem

2009-08-25 Thread Michael Bayer
Martijn Faassen wrote: Michael Bayer wrote: 1. whats this ? File bin/devpython, line 25, in ? execfile(sys.argv[0]) That's a buildout-generated Python script that just controls what's on the python path. It effectively behaves like the Python interpreter. I've never had any

[sqlalchemy] Re: composite primary key problem

2009-08-25 Thread Martijn Faassen
Hey Michael, Cool that you managed to reproduce the issue. Michael Bayer wrote: and a potential fix is this: Index: lib/sqlalchemy/orm/session.py === --- lib/sqlalchemy/orm/session.py (revision 6289) +++

[sqlalchemy] Re: composite primary key problem

2009-08-25 Thread Michael Bayer
Martijn Faassen wrote: Hey Michael, Cool that you managed to reproduce the issue. Michael Bayer wrote: and a potential fix is this: Index: lib/sqlalchemy/orm/session.py === --- lib/sqlalchemy/orm/session.py(revision

[sqlalchemy] Re: composite primary key problem

2009-08-24 Thread Michael Bayer
the program works for me, I get: 2009-08-24 16:12:56,797 INFO sqlalchemy.engine.base.Engine.0x...1830 PRAGMA table_info(user) 2009-08-24 16:12:56,806 INFO sqlalchemy.engine.base.Engine.0x...1830 () 2009-08-24 16:12:56,807 INFO sqlalchemy.engine.base.Engine.0x...1830 CREATE TABLE user (