Commits

Aurélien Matouillot committed 6a8cb59 Draft

Add info parameter for the RelationshipProperty like for the Column and Table

Comments (0)

Files changed (2)

lib/sqlalchemy/orm/__init__.py

       not compile into eager or lazy loaders properly. If this is the
       case, use an alternative method.
 
+    :param info: 
+      A dictionary which defaults to ``{}``. A space to store
+      application specific data. This must be a dictionary.
+
     """
     return RelationshipProperty(argument, secondary=secondary, **kwargs)
 

lib/sqlalchemy/orm/properties.py

         cascade_backrefs=True,
         load_on_pending=False,
         strategy_class=None, _local_remote_pairs=None,
-        query_class=None):
+        query_class=None, info=None):
 
         self.uselist = uselist
         self.argument = argument
         else:
             self.backref = backref
 
+        self.info = info or {}
+
     def instrument_class(self, mapper):
         attributes.register_descriptor(
             mapper.class_,