Add list of possible keys to 'block info' error for key discovery.
authorW. Trevor King <wking@drexel.edu>
Thu, 2 Sep 2010 10:23:05 +0000 (06:23 -0400)
committerW. Trevor King <wking@drexel.edu>
Thu, 2 Sep 2010 10:23:05 +0000 (06:23 -0400)
hooke/plugin/curve.py

index 92e5bd1bb8a1aeba4b5ca90597c6f685d154fe0d..20d4e5e32e4cbf99d3f4c1debd757a341a417540 100644 (file)
@@ -388,8 +388,9 @@ File name for the output (appended).
                         else:
                             keys.append((index+1, new_stack, v))
                 if matched == False:
-                    raise ValueError('no match found for %s in %s'
-                                     % (key_stack[index], key))
+                    raise ValueError(
+                        'no match found for %s (%s) in %s'
+                        % (key_stack[index], key, sorted(info.keys())))
         if params['output'] != None:
             curve = self._curve(hooke, params)
             with open(params['output'], 'a') as f: