# Rdoc breaks on some types of links

**URL:** <https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543>\
**Category:** Ruby\
**Created:** [May 14, 2008, 3:20am UTC](https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543 "2008-05-14T03:20:52Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Joel\_VanderWerf](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/e19b73/32.png) [@Joel\_VanderWerf](https://www.ruby-forum.com/u/Joel_VanderWerf)\
**Post date:** [May 14, 2008, 3:20am UTC](https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543/1 "2008-05-14T03:20:52Z")

</div>

Not sure exactly which link is causing this, but it seems like bug in  
rdoc (and it wasn’t a problem in earlier versions):

/usr/local/lib/ruby/gems/1.8/gems/rdoc-2.0.0/lib/rdoc/markup/to\_html.rb:50:in  
`gen_url': uninitialized constant RDoc::Markup::ToHtml::HTML (NameError) from /usr/local/lib/ruby/gems/1.8/gems/rdoc-2.0.0/lib/rdoc/markup/to_html.rb:86:in`handle\_special\_TIDYLINK’

---

<div class="post-metadata">

**Author:** ![Joel\_VanderWerf](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/e19b73/32.png) [@Joel\_VanderWerf](https://www.ruby-forum.com/u/Joel_VanderWerf)\
**Post date:** [May 14, 2008, 9:23am UTC](https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543/2 "2008-05-14T09:23:15Z")

</div>

On May 13, 2008, at 18:20 , Joel VanderWerf wrote:

> Not sure exactly which link is causing this, but it seems like bug  
> in rdoc (and it wasn’t a problem in earlier versions):
> 
> /usr/local/lib/ruby/gems/1.8/gems/rdoc-2.0.0/lib/rdoc/markup/  
> to\_html.rb:50:in `gen_url': uninitialized constant RDoc::Markup::ToHtml::HTML (NameError) from /usr/local/lib/ruby/gems/1.8/gems/rdoc-2.0.0/lib/rdoc/ markup/to_html.rb:86:in`handle\_special\_TIDYLINK’

do you know how to repro that?

was it a specific gem installed or command that caused it?

Also, filing a bug is preferred.

---

<div class="post-metadata">

**Author:** ![Joel\_VanderWerf](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/e19b73/32.png) [@Joel\_VanderWerf](https://www.ruby-forum.com/u/Joel_VanderWerf)\
**Post date:** [May 14, 2008, 6:18pm UTC](https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543/3 "2008-05-14T18:18:30Z")

</div>

Ryan D. wrote:

> > `handle\_special\_TIDYLINK’
> 
> do you know how to repro that?
> 
> was it a specific gem installed or command that caused it?
> 
> Also, filing a bug is preferred.

Sorry, that was very vague. I was hoping that it was something obvious  
about that line.

Will try to reproduce it and file a bug if I can make it concise…

Where should it be finding that constant, RDoc::Markup::ToHtml::HTML,  
anyway? The file markup/to\_html.rb doesn’t seem to define it, and grep  
doesn’t find it:

$ grep -P '(class|module)._HTML’ \*\*/_.rb  
generator/chm.rb:class RDoc::Generator::CHM \< RDoc::Generator::HTML  
generator/html/hefss.rb:module RDoc::Generator::HTML::HEFSS  
generator/html/html.rb:module RDoc::Generator::HTML::HTML  
generator/html/kilmer.rb:module RDoc::Generator::HTML::KILMER  
generator/html/one\_page\_html.rb:module  
RDoc::Generator::HTML::ONE\_PAGE\_HTML  
generator/html.rb:class RDoc::Generator::HTML  
generator/html.rb:class RDoc::Generator::HTMLInOne \<  
RDoc::Generator::HTML  
generator/xml.rb:class RDoc::Generator::XML \< RDoc::Generator::HTML  
markup.rb:# strike-through text. When then subclass the HTML output  
class to deal  
markup/to\_flow.rb: # required. This is a no-op in the base class, but  
is overridden in HTML  
markup/to\_html.rb: # required. This is a no-op in the base class, but  
is overridden in HTML

---

<div class="post-metadata">

**Author:** ![Joel\_VanderWerf](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/e19b73/32.png) [@Joel\_VanderWerf](https://www.ruby-forum.com/u/Joel_VanderWerf)\
**Post date:** [June 14, 2008, 2:45am UTC](https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543/4 "2008-06-14T02:45:38Z")

</div>

Joel VanderWerf wrote:

> > > /usr/local/lib/ruby/gems/1.8/gems/rdoc-2.0.0/lib/rdoc/markup/to\_html.rb:86:in
> 
> generator/html/kilmer.rb:module RDoc::Generator::HTML::KILMER  
> generator/html/one\_page\_html.rb:module RDoc::Generator::HTML::ONE\_PAGE\_HTML  
> generator/html.rb:class RDoc::Generator::HTML  
> generator/html.rb:class RDoc::Generator::HTMLInOne \< RDoc::Generator::HTML  
> generator/xml.rb:class RDoc::Generator::XML \< RDoc::Generator::HTML  
> markup.rb:# strike-through text. When then subclass the HTML output  
> class to deal  
> markup/to\_flow.rb: # required. This is a no-op in the base class, but  
> is overridden in HTML  
> markup/to\_html.rb: # required. This is a no-op in the base class, but  
> is overridden in HTML

Ok found the cause of the bug, if it is a bug (maybe it’s just a change  
in 2.0).

$ cat bug.rb

# [{foo/}[link:foo/]]

def bar  
end

I’ll file this on the tracker.

---

<div class="post-metadata">

**Author:** ![Joel\_VanderWerf](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/e19b73/32.png) [@Joel\_VanderWerf](https://www.ruby-forum.com/u/Joel_VanderWerf)\
**Post date:** [June 14, 2008, 2:59am UTC](https://www.ruby-forum.com/t/rdoc-breaks-on-some-types-of-links/137543/5 "2008-06-14T02:59:40Z")

</div>

Joel VanderWerf wrote:

> Ok found the cause of the bug, if it is a bug (maybe it’s just a change  
> in 2.0).
> 
> $ cat bug.rb
> 
> # [{foo/}[link:foo/]]
> 
> def bar  
> end
> 
> I’ll file this on the tracker.

…and there already a report of this, from April, in

[http://rubyforge.org/tracker/index.php?func=detail&aid=19387&group\_id=627&atid=2472](http://rubyforge.org/tracker/index.php?func=detail&aid=19387&group_id=627&atid=2472)
