File tree Expand file tree Collapse file tree 1 file changed +9
-11
lines changed Expand file tree Collapse file tree 1 file changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -109,17 +109,15 @@ def add_to_error_path(self, path):
109
109
self .path = [path ] + self .path
110
110
111
111
def __str__ (self ):
112
- message = self .message
113
- message += "\n \n Path To Error:\n ["
114
- for iii , key in enumerate (self .path ):
115
- message += repr (key )
116
- if iii < len (self .path ) - 1 :
117
- message += "]["
118
- message += "]"
119
- if len (self .notes ):
120
- message += "\n \n Additional Notes:\n {0}" .format (
121
- "\n " .join (self .notes ))
122
- return message
112
+ format_dict = {
113
+ 'message' : self .message ,
114
+ 'path' : '[' + '][' .join (repr (k ) for k in self .path ) + ']' ,
115
+ 'notes' : '\n ' .join (self .notes )
116
+ }
117
+ return (
118
+ '{message}\n \n Path To Error: {path}\n \n Additional Notes:\n {notes}'
119
+ .format (** format_dict )
120
+ )
123
121
124
122
125
123
class PlotlyDictKeyError (PlotlyGraphObjectError ):
You can’t perform that action at this time.
0 commit comments