From 460ea45061e9587898a682c71740bd3831c38d09 Mon Sep 17 00:00:00 2001 From: Jan Dittberner Date: Sat, 7 May 2016 00:17:28 +0200 Subject: [PATCH] Fix index generation issue Index keys were wrongly defined as empty string which caused garbage in the resulting index this commit changes the empty string to None. The version number has been incremented. --- CHANGES.rst | 5 +++++ jandd/sphinxext/ip.py | 6 +++--- setup.py | 2 +- 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/CHANGES.rst b/CHANGES.rst index 0c4519a..a33c275 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -1,6 +1,11 @@ Changes ======= +0.2.4 - unreleased +------------------ + +* fix index generation issue + 0.2.3 - 2016-05-05 ------------------ diff --git a/jandd/sphinxext/ip.py b/jandd/sphinxext/ip.py index eb8f760..e390667 100644 --- a/jandd/sphinxext/ip.py +++ b/jandd/sphinxext/ip.py @@ -23,7 +23,7 @@ from sphinx.locale import l_ from sphinx.roles import XRefRole from sphinx.util.nodes import make_refnode -__version__ = '0.2.3' +__version__ = '0.2.4' def ip_object_anchor(typ, path): @@ -120,8 +120,8 @@ class IPRange(Directive): doctitle = self.state.document.traverse(nodes.title)[0].astext() idx_text = "%s; %s" % (self.rangespec, doctitle) self.indexnode = addnodes.index(entries=[ - ('single', idx_text, name, '', ''), - ('single', self.get_index_text(), name, '', '') + ('single', idx_text, name, '', None), + ('single', self.get_index_text(), name, '', None) ]) if self.content: diff --git a/setup.py b/setup.py index 38b7cb9..77907b8 100644 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ from setuptools import setup, find_packages -version = '0.2.3' +version = '0.2.4' with open('README.rst') as readme: description = readme.read() + "\n\n"