##// END OF EJS Templates
Guard against self.state is None
y-p -
Show More
@@ -429,8 +429,11 b' class EmbeddedSphinxShell(object):'
429 ret.append('')
429 ret.append('')
430
430
431 # context information
431 # context information
432 filename = self.state.document.current_source
432 filename = "Unknown"
433 lineno = self.state.document.current_line
433 lineno = 0
434 if self.state:
435 filename = self.state.document.current_source
436 lineno = self.state.document.current_line
434
437
435 # output any exceptions raised during execution to stdout
438 # output any exceptions raised during execution to stdout
436 # unless :okexcept: has been specified.
439 # unless :okexcept: has been specified.
General Comments 0
You need to be logged in to leave comments. Login now