[Checkins] SVN: z3c.dobbin/trunk/src/z3c/dobbin/ API update.

Malthe Borch mborch at gmail.com
Tue Aug 5 14:11:35 EDT 2008


Log message for revision 89414:
  API update.

Changed:
  U   z3c.dobbin/trunk/src/z3c/dobbin/bootstrap.py
  U   z3c.dobbin/trunk/src/z3c/dobbin/mapper.py

-=-
Modified: z3c.dobbin/trunk/src/z3c/dobbin/bootstrap.py
===================================================================
--- z3c.dobbin/trunk/src/z3c/dobbin/bootstrap.py	2008-08-05 18:03:19 UTC (rev 89413)
+++ z3c.dobbin/trunk/src/z3c/dobbin/bootstrap.py	2008-08-05 18:11:35 UTC (rev 89414)
@@ -16,6 +16,9 @@
     def get_col_spec(self):
         return "UUID"
 
+def get_soup_table():
+    return Soup._sa_class_manager.mapper.local_table
+
 def initialize(event=None):
     """Database initialization.
 

Modified: z3c.dobbin/trunk/src/z3c/dobbin/mapper.py
===================================================================
--- z3c.dobbin/trunk/src/z3c/dobbin/mapper.py	2008-08-05 18:03:19 UTC (rev 89413)
+++ z3c.dobbin/trunk/src/z3c/dobbin/mapper.py	2008-08-05 18:11:35 UTC (rev 89414)
@@ -130,9 +130,8 @@
             del properties[name]
             setattr(Mapper, name, prop)
 
-    # XXX: there must be a more straight-forward way to do this
-    soup_table = bootstrap.Soup._sa_class_manager.mappers[None].local_table
-    
+    soup_table = bootstrap.get_soup_table()
+        
     polymorphic = (
         [Mapper], table.join(
         soup_table, first_table.c.id==soup_table.c.id))
@@ -199,7 +198,7 @@
         
     kw = dict(useexisting=True)
 
-    soup_table = bootstrap.Soup._sa_class_manager.mappers[None].local_table
+    soup_table = bootstrap.get_soup_table()
 
     table = rdb.Table(
         name,



More information about the Checkins mailing list