]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
Fixed a regression in the examples/dogpile_caching example
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 8 Jan 2013 15:59:26 +0000 (10:59 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 8 Jan 2013 15:59:26 +0000 (10:59 -0500)
which was due to the change in #2614.

doc/build/changelog/changelog_08.rst
examples/dogpile_caching/caching_query.py

index b8ae66e44d4aa951a2f307d8c730dc57161714c7..3f7a488489ccb90353edc95039cb99f434b075b0 100644 (file)
@@ -6,6 +6,12 @@
 .. changelog::
     :version: 0.8.0
 
+    .. change::
+        :tags: examples, bug
+
+      Fixed a regression in the examples/dogpile_caching example
+      which was due to the change in :ticket:`2614`.
+
     .. change::
         :tags: orm, bug
         :tickets: 2640
index fb532fa63d4b78f7bcb3a595024715f028b729a9..9a705cf31459a541c42ce59adf47f71e629b74e6 100644 (file)
@@ -233,7 +233,8 @@ class RelationshipCache(MapperOption):
 
         """
         if query._current_path:
-            mapper, key = query._current_path[-2:]
+            mapper, prop = query._current_path[-2:]
+            key = prop.key
 
             for cls in mapper.class_.__mro__:
                 if (cls, key) in self._relationship_options: