From: Michael Trier Date: Sat, 19 Jul 2008 17:52:31 +0000 (+0000) Subject: Corrected a couple of lingering transactional=True statements in the docs. X-Git-Tag: rel_0_5beta3~31 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c75aed9be1941144c390673709861e86c1a3e14;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git Corrected a couple of lingering transactional=True statements in the docs. --- diff --git a/doc/build/content/plugins.txt b/doc/build/content/plugins.txt index 5f795d4974..29d9c4b623 100644 --- a/doc/build/content/plugins.txt +++ b/doc/build/content/plugins.txt @@ -217,7 +217,7 @@ and Table objects. A typical application setup using `scoped_session` might look {python} engine = create_engine('postgres://scott:tiger@localhost/test') - Session = scoped_session(sessionmaker(transactional=True, autoflush=False, bind=engine)) + Session = scoped_session(sessionmaker(autocommit=False, autoflush=False, bind=engine)) Base = declarative_base() Mapped instances then make usage of `Session` in the usual way. diff --git a/lib/sqlalchemy/ext/declarative.py b/lib/sqlalchemy/ext/declarative.py index 68a0d8e81d..f8008ab8b0 100644 --- a/lib/sqlalchemy/ext/declarative.py +++ b/lib/sqlalchemy/ext/declarative.py @@ -192,7 +192,7 @@ objects. A typical application setup using ``scoped_session`` might look like:: engine = create_engine('postgres://scott:tiger@localhost/test') - Session = scoped_session(sessionmaker(transactional=True, + Session = scoped_session(sessionmaker(autocommit=False, autoflush=False, bind=engine)) Base = declarative_base() diff --git a/lib/sqlalchemy/orm/session.py b/lib/sqlalchemy/orm/session.py index 289294f4ce..fbfcd51c6b 100644 --- a/lib/sqlalchemy/orm/session.py +++ b/lib/sqlalchemy/orm/session.py @@ -746,7 +746,7 @@ class Session(object): This clears all items and ends any transaction in progress. - If this session were created with ``transactional=True``, a new + If this session were created with ``autocommit=False``, a new transaction is immediately begun. Note that this new transaction does not use any connection resources until they are first needed.