pshell+sqlalchemy = ?

2013-05-30 Thread Sergej Wouldnttell
Hello, community! Could you please help me to find the root of a problem: # DBSession = scoped_session(sessionmaker(extension=ZopeTransactionExtension())) # n = DBSession.query(SportTeamNew).filter(SportTeamNew.title == team_name).one() n.hits += 1 DBSession.add(n) #I've cut all useless here

Re: pshell+sqlalchemy = ?

2013-05-30 Thread Mariano Mara
On 05/30/2013 01:38 PM, Sergej Wouldnttell wrote: Hello, community! Could you please help me to find the root of a problem: # DBSession = scoped_session(sessionmaker(extension=ZopeTransactionExtension())) # n = DBSession.query(SportTeamNew).filter(SportTeamNew.title == team_name).one() n.hits

Re: pshell+sqlalchemy = ?

2013-05-30 Thread Laurent DAVERIO
Le 30/05/13 18:51, Rachid Belaid a écrit : I met the same is issues. I think that you can simply do `Session.commit()` base on my pshell history In my experience, Session.commit() fails with an AssertionError exception: AssertionError: Transaction must be committed using the transaction

Re: pshell+sqlalchemy = ?

2013-05-30 Thread wshaman
On 05/30/2013 01:38 PM, Sergej Wouldnttell wrote: Hello, community! Could you please help me to find the root of a problem: # DBSession = scoped_session(sessionmaker(extension=ZopeTransactionExtension())) # n = DBSession.query(SportTeamNew).filter(SportTeamNew.title ==