##// END OF EJS Templates
Backport PR #14022: Fix failing docs build.
Matthias Bussonnier -
Show More
@@ -194,6 +194,13 b' class IPythonTracebackLexer(DelegatingLexer):'
194 aliases = ['ipythontb']
194 aliases = ['ipythontb']
195
195
196 def __init__(self, **options):
196 def __init__(self, **options):
197 """
198 A subclass of `DelegatingLexer` which delegates to the appropriate to either IPyLexer,
199 IPythonPartialTracebackLexer.
200 """
201 # note we need a __init__ doc, as otherwise it inherits the doc from the super class
202 # which will fail the documentation build as it references section of the pygments docs that
203 # do not exists when building IPython's docs.
197 self.python3 = get_bool_opt(options, 'python3', False)
204 self.python3 = get_bool_opt(options, 'python3', False)
198 if self.python3:
205 if self.python3:
199 self.aliases = ['ipython3tb']
206 self.aliases = ['ipython3tb']
@@ -503,6 +510,13 b' class IPyLexer(Lexer):'
503 aliases = ['ipy']
510 aliases = ['ipy']
504
511
505 def __init__(self, **options):
512 def __init__(self, **options):
513 """
514 Create a new IPyLexer instance which dispatch to either an
515 IPythonCOnsoleLexer (if In prompts are present) or and IPythonLexer (if
516 In prompts are not present).
517 """
518 # init docstring is necessary for docs not to fail to build do to parent
519 # docs referenceing a section in pygments docs.
506 self.python3 = get_bool_opt(options, 'python3', False)
520 self.python3 = get_bool_opt(options, 'python3', False)
507 if self.python3:
521 if self.python3:
508 self.aliases = ['ipy3']
522 self.aliases = ['ipy3']
General Comments 0
You need to be logged in to leave comments. Login now