diff --git a/CHANGES b/CHANGES index 77e8b1bcb..4ebc4842f 100644 --- a/CHANGES +++ b/CHANGES @@ -88,6 +88,7 @@ Bugs fixed * #3284: Sphinx crashes on parallel build with an extension which raises unserializable exception * #3315: Bibliography crashes on latex build with docclass 'memoir' +* #3328: Could not refer rubric implicitly Release 1.5.1 (released Dec 13, 2016) diff --git a/setup.cfg b/setup.cfg index 73ac1e746..e341d921a 100644 --- a/setup.cfg +++ b/setup.cfg @@ -25,5 +25,5 @@ universal = 1 [flake8] max-line-length = 95 -ignore = E113,E116,E221,E226,E241,E251,E901 +ignore = E116,E241,E251 exclude = .git,.tox,tests/*,build/*,sphinx/search/*,sphinx/pycode/pgen2/*,doc/ext/example*.py diff --git a/sphinx/__init__.py b/sphinx/__init__.py index ad9493ecd..0c931cd4d 100644 --- a/sphinx/__init__.py +++ b/sphinx/__init__.py @@ -30,7 +30,7 @@ if 'PYTHONWARNINGS' not in os.environ: warnings.filterwarnings('ignore', "'U' mode is deprecated", DeprecationWarning, module='docutils.io') -__version__ = '1.6' +__version__ = '1.6' __released__ = '1.6+' # used when Sphinx builds its own docs # version info for better programmatic use diff --git a/sphinx/apidoc.py b/sphinx/apidoc.py index e48a527a5..0fca17d81 100644 --- a/sphinx/apidoc.py +++ b/sphinx/apidoc.py @@ -384,8 +384,8 @@ Note: By default this script will not overwrite already created files.""") text += ' %s\n' % module d = dict( path = opts.destdir, - sep = False, - dot = '_', + sep = False, + dot = '_', project = opts.header, author = opts.author or 'Author', version = opts.version or '', diff --git a/sphinx/application.py b/sphinx/application.py index c5634b4ca..6ea7b059f 100644 --- a/sphinx/application.py +++ b/sphinx/application.py @@ -632,9 +632,9 @@ class Sphinx(object): else: # ignore invalid keys for compatibility continue - setattr(translator, 'visit_'+node.__name__, visit) + setattr(translator, 'visit_' + node.__name__, visit) if depart: - setattr(translator, 'depart_'+node.__name__, depart) + setattr(translator, 'depart_' + node.__name__, depart) def add_enumerable_node(self, node, figtype, title_getter=None, **kwds): # type: (nodes.Node, unicode, Callable, Any) -> None diff --git a/sphinx/builders/changes.py b/sphinx/builders/changes.py index d6e118d97..fc8532794 100644 --- a/sphinx/builders/changes.py +++ b/sphinx/builders/changes.py @@ -141,7 +141,7 @@ class ChangesBuilder(Builder): targetfn = path.join(self.outdir, 'rst', os_path(docname)) + '.html' ensuredir(path.dirname(targetfn)) with codecs.open(targetfn, 'w', 'utf-8') as f: # type: ignore - text = ''.join(hl(i+1, line) for (i, line) in enumerate(lines)) + text = ''.join(hl(i + 1, line) for (i, line) in enumerate(lines)) ctx = { 'filename': self.env.doc2path(docname, None), 'text': text diff --git a/sphinx/builders/html.py b/sphinx/builders/html.py index 04d63a046..f7fe53cac 100644 --- a/sphinx/builders/html.py +++ b/sphinx/builders/html.py @@ -522,7 +522,7 @@ class StandaloneHTMLBuilder(Builder): # additional pages from conf.py for pagename, template in self.config.html_additional_pages.items(): - logger.info(' '+pagename, nonl=1) + self.info(' ' + pagename, nonl=1) self.handle_page(pagename, {}, template) # the search page @@ -1003,7 +1003,7 @@ class SingleFileHTMLBuilder(StandaloneHTMLBuilder): hashindex = refuri.find('#') if hashindex < 0: continue - hashindex = refuri.find('#', hashindex+1) + hashindex = refuri.find('#', hashindex + 1) if hashindex >= 0: refnode['refuri'] = fname + refuri[hashindex:] @@ -1116,7 +1116,7 @@ class SingleFileHTMLBuilder(StandaloneHTMLBuilder): # additional pages from conf.py for pagename, template in self.config.html_additional_pages.items(): - logger.info(' '+pagename, nonl=1) + self.info(' ' + pagename, nonl=1) self.handle_page(pagename, {}, template) if self.config.html_use_opensearch: diff --git a/sphinx/builders/htmlhelp.py b/sphinx/builders/htmlhelp.py index 852700123..08e6f9df4 100644 --- a/sphinx/builders/htmlhelp.py +++ b/sphinx/builders/htmlhelp.py @@ -215,12 +215,12 @@ class HTMLHelpBuilder(StandaloneHTMLBuilder): def build_hhx(self, outdir, outname): logger.info('dumping stopword list...') - with self.open_file(outdir, outname+'.stp') as f: + with self.open_file(outdir, outname + '.stp') as f: for word in sorted(stopwords): print(word, file=f) logger.info('writing project file...') - with self.open_file(outdir, outname+'.hhp') as f: + with self.open_file(outdir, outname + '.hhp') as f: f.write(project_template % { 'outname': outname, 'title': self.config.html_title, @@ -241,7 +241,7 @@ class HTMLHelpBuilder(StandaloneHTMLBuilder): file=f) logger.info('writing TOC file...') - with self.open_file(outdir, outname+'.hhc') as f: + with self.open_file(outdir, outname + '.hhc') as f: f.write(contents_header) # special books f.write('
  • ' + object_sitemap % (self.config.html_short_title, @@ -266,7 +266,7 @@ class HTMLHelpBuilder(StandaloneHTMLBuilder): if ullevel != 0: f.write('\n') elif isinstance(node, addnodes.compact_paragraph): @@ -282,7 +282,7 @@ class HTMLHelpBuilder(StandaloneHTMLBuilder): logger.info('writing index file...') index = self.env.create_index(self) - with self.open_file(outdir, outname+'.hhk') as f: + with self.open_file(outdir, outname + '.hhk') as f: f.write('