Ill cut to the chase and include the patch that resolved the issue.
--- a/sphinx/environment.py Thu Apr 09 21:38:36 2009 +0200
+++ b/sphinx/environment.py Fri Apr 10 01:42:26 2009 -0700
@@ -534,7 +534,7 @@
"""
Custom decoding error handler that warns and replaces.
"""
- linestart = error.object.rfind('\n', None, error.start)
+ linestart = error.object.rfind('\n', 0, error.start)
lineend = error.object.find('\n', error.start)
if lineend == -1: lineend = len(error.object)
lineno = error.object.count('\n', 0, error.start) + 1
The problem I was seeing is listed below. The solution itself makes
no sense to me at all, because the error message itself says None is
valid. All I know is if I make the code change everything works
again.
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/environment.py",
line 537, in warn_and_replace
linestart = error.object.rfind('\n', None, error.start)
TypeError: slice indices must be integers or None or have an __index__ method
Traceback (most recent call last):
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/cmdline.py",
line 172, in main
app.build(all_files, filenames)
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/application.py",
line 129, in build
self.builder.build_update()
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/builders/__init__.py",
line 255, in build_update
'out of date' % len(to_build))
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/builders/__init__.py",
line 275, in build
purple, length):
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/builders/__init__.py",
line 131, in status_iterator
for item in iterable:
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/environment.py",
line 513, in update_generator
self.read_doc(docname, app=app)
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/environment.py",
line 604, in read_doc
pub.publish()
File
"/usr/lib/python2.5/site-packages/docutils-0.5-py2.5.egg/docutils/core.py",
line 204, in publish
self.settings)
File
"/usr/lib/python2.5/site-packages/docutils-0.5-py2.5.egg/docutils/readers/__init__.py",
line 68, in read
self.input = self.source.read()
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/environment.py",
line 584, in read
data = FileInput.read(self_)
File "/usr/lib/python2.5/site-packages/docutils-0.5-py2.5.egg/docutils/io.py",
line 275, in read
return self.decode(data)
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/environment.py",
line 581, in decode
return data.decode(self_.encoding, 'sphinx')
File "/usr/lib/python2.5/encodings/utf_8.py", line 16, in decode
return codecs.utf_8_decode(input, errors, True)
File
"/usr/lib/python2.5/site-packages/Sphinx-0.6.1-py2.5.egg/sphinx/environment.py",
line 537, in warn_and_replace
linestart = error.object.rfind('\n', None, error.start)
TypeError: slice indices must be integers or None or have an __index__ method
PS. I really likely Sphinx.
--
John Cavanaugh
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sphinx-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sphinx-dev?hl=en
-~----------~----~----~----~------~----~------~--~---