@@ -117,6 +117,8 @@ def run(self, action, identifier, **kwargs):
117
117
# Then get the model class for the object path
118
118
model_class = self .get_model_class (object_path , ** kwargs )
119
119
current_index = self .get_index (model_class , ** kwargs )
120
+ current_index_name = "." .join ([current_index .__class__ .__module__ ,
121
+ current_index .__class__ .__name__ ])
120
122
121
123
if action == 'delete' :
122
124
# If the object is gone, we'll use just the identifier
@@ -128,17 +130,17 @@ def run(self, action, identifier, **kwargs):
128
130
logger .error (exc )
129
131
self .retry (exc = exc )
130
132
else :
131
- msg = ("Deleted '%s' from index %s " %
132
- (identifier , current_index ))
133
+ msg = ("Deleted '%s' (with %s) " %
134
+ (identifier , current_index_name ))
133
135
logger .debug (msg )
134
136
return msg
135
137
136
138
elif action == 'update' :
137
139
# and the instance of the model class with the pk
138
140
instance = self .get_instance (model_class , pk , ** kwargs )
139
141
if instance is None :
140
- logger .debug ("Didn't update index %s for '%s' " %
141
- (current_index , identifier ))
142
+ logger .debug ("Failed updating '%s' (with %s) " %
143
+ (identifier , current_index_name ))
142
144
raise ValueError ("Couldn't load object '%s'" % identifier )
143
145
144
146
# Call the appropriate handler of the current index and
@@ -150,8 +152,8 @@ def run(self, action, identifier, **kwargs):
150
152
logger .error (exc )
151
153
self .retry (exc = exc )
152
154
else :
153
- msg = ("Updated index %s with '%s' " %
154
- (current_index , instance ))
155
+ msg = ("Updated '%s' ( with %s) " %
156
+ (identifier , current_index_name ))
155
157
logger .debug (msg )
156
158
return msg
157
159
else :
0 commit comments