[ditz-talk] HTML rendering bug on trivially malformed project.yaml
ohad at lutzky.net
Sun Aug 17 13:23:27 EDT 2008
For some reason, my project.yaml file became corrupted in a minute
way: In one of the releases' log_events, the terminating '- ""' line
was missing. This can be reproduced like so:
Edit bugs/project.yaml and remove the last line
The error I get is:
$ ditz html
(erb):56:in `render_template': undefined method `empty?' for
from (erb):68:in `each_with_index'
from (erb):45:in `each'
from (erb):45:in `each_with_index'
from (erb):45:in `render_template'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/html.rb:23:in `render_template'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/views.rb:99:in `render_all'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/views.rb:98:in `open'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/views.rb:98:in `render_all'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/views.rb:95:in `each'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/views.rb:95:in `render_all'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/operator.rb:425:in `html'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/operator.rb:100:in `send'
from /usr/lib/ruby/gems/1.8/gems/ditz-0.4/lib/operator.rb:100:in `do'
from /usr/bin/ditz:19:in `load'
This also occurs for current mainline git ditz.
I believe that ditz html should be resilient to this problem, as the
rest of ditz is. If not, a more intelligible error message should be
presented (it took me way too long to figure this one out).
Man is the only animal that laughs and weeps, for he is the only
animal that is struck with the difference between what things are and
what they ought to be.
- William Hazlitt
More information about the ditz-talk