summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/orm/scoping.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/sqlalchemy/orm/scoping.py')
-rw-r--r--lib/sqlalchemy/orm/scoping.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/sqlalchemy/orm/scoping.py b/lib/sqlalchemy/orm/scoping.py
index 431377da0..1068f6704 100644
--- a/lib/sqlalchemy/orm/scoping.py
+++ b/lib/sqlalchemy/orm/scoping.py
@@ -22,10 +22,10 @@ class ScopedSession(object):
Session = scoped_session(sessionmaker())
... use Session normally.
-
+
The internal registry is accessible as well,
and by default is an instance of :class:`.ThreadLocalRegistry`.
-
+
"""
@@ -54,14 +54,14 @@ class ScopedSession(object):
def remove(self):
"""Dispose of the current contextual session."""
-
+
if self.registry.has():
self.registry().close()
self.registry.clear()
def configure(self, **kwargs):
"""reconfigure the sessionmaker used by this ScopedSession."""
-
+
if self.registry.has():
warn('At least one scoped session is already present. '
' configure() can not affect sessions that have '
@@ -74,7 +74,7 @@ class ScopedSession(object):
class when called.
e.g.::
-
+
Session = scoped_session(sessionmaker())
class MyClass(object):