Planet Venus & multiple Django templates
Justin Dugger
jldugger at ubuntu.com
Fri Mar 12 17:23:40 EST 2010
It seems I've run into a bug in planet venus, when using Django to
output both HTML and RSS.
With the following theme config.ini:
[Planet]
template_files:
rss20.xml.dj
index.html.dj
I get:
$ planet /etc/planet/planet.ini
Traceback (most recent call last):
File "/usr/bin/planet", line 138, in <module>
splice.apply(doc.toxml('utf-8'))
File "/usr/lib/pymodules/python2.6/planet/splice.py", line 118, in apply
output_file = shell.run(template_file, doc)
File "/usr/lib/pymodules/python2.6/planet/shell/__init__.py", line 66, in run
module.run(template_resolved, doc, output_file, options)
File "/usr/lib/pymodules/python2.6/planet/shell/dj.py", line 25, in run
TEMPLATE_DIRS=(os.path.dirname(script),)
File "/usr/lib/pymodules/python2.6/django/conf/__init__.py", line
49, in configure
raise RuntimeError, 'Settings already configured.
Each template works fine on its own, but when both are supplied it
fails. As a workaround I think I can just invoke planet twice with
seperate config files, but perhaps it's as easy as catching the
runtime error and continuing?
Justin Dugger
More information about the devel
mailing list