I did exactly the same and got exactly the same cryptic error. Thanks very 
much for posting your solution! Consider posting it on stackoverflow so 
that it might reach a wider audience?
Tris

On Wednesday, 15 June 2011 03:01:00 UTC+1, Andrew Tipton wrote:
>
> Hello all, 
>
> I've encountered a fairly bizarre Sphinx error (now solved) which I 
> wanted to share with the list.  I'm a new user of Sphinx, and this was 
> my first try at using it to document something. 
>
> I started by creating a fresh environment using sphinx-quickstart, and 
> added the 'sphinx_http_domain' extension (at 
> http://pypi.python.org/pypi/sphinx-http-domain/0.2). 
> I added a bit of documentation, and built it with 'make html'.  But my 
> 'http:get' and 'http:post' directives weren't recognized. 
>
> A bit of investigation led me to realize that I was actually reading 
> the documentation for an entirely different module, 
> 'sphinxcontrib.httpdomain' (http://packages.python.org/sphinxcontrib- 
> httpdomain/ <http://packages.python.org/sphinxcontrib-httpdomain/>) -- 
> silly me!  So I installed that module, edited my 
> conf.py to disable sphinx_http_domain and enable 
> sphinxcontrib.httpdomain, and re-ran 'make html'. 
>
> Imagine my surprise when httpdomain bailed out with a KeyError!  After 
> a rather long trek through the Sphinx codebase, I discovered the 
> offending code in domains/__init__.py line 145, where env.domaindata 
> is only initialized with self.initial_data *if it hasn't been 
> previously initialized*.  Well, env.domaindata['http'] was 
> initialized, but it had the contents from sphinx_http_domain's 
> initial_data dict instead of sphinxcontrib.httpdomain's initial_data. 
>
> Removing the pickled environment in my _build directory allowed 
> everything to build correctly. 
>
> I have no specific suggestions to make on how to fix this, but I'd 
> like to note that this was a fairly difficult issue to debug. 
>
>
> Cheers, 
> Andrew Tipton

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/sphinx-dev/-/2oBrTMArTBYJ.
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.

Reply via email to