Timeout in microformats.rb

1 view
Skip to first unread message

Alcides Fonseca

unread,
Jan 19, 2008, 6:44:03 PM1/19/08
to mofo
I am working on a simple project and I'm using mofo to fetch
microformats from other pages. I've noticed that for specially blogs
the default timeout of 3 seconds to open the file is not enought. I've
change it to 30 seconds and it works now.

The point here is that I manually changed the time out. I believe it
should be something we could change in the code, without affecting the
whole library.

Take this in consideration since it's not that hard to do.

Thanks

Alcides Fonseca

Chris Wanstrath

unread,
Jan 19, 2008, 7:03:37 PM1/19/08
to mof...@googlegroups.com
On 1/19/08, Alcides Fonseca <alcides...@gmail.com> wrote:

> The point here is that I manually changed the time out. I believe it
> should be something we could change in the code, without affecting the
> whole library.

Can you explain what you mean?

To change the timeout, you can currently do this:

Mofo.timeout = 30

--
Chris Wanstrath
http://errfree.com // http://errtheblog.com
http://github.com // http://famspam.com

Alcides Fonseca

unread,
Jan 19, 2008, 7:49:48 PM1/19/08
to mofo
Weird...

That works on the console, but in the CGI script I am running in my
host ( microformat and mofo go along with it), it doesn't work.

[Sat Jan 19 16:40:12 2008] [error] [client 82.154.53.56] File does not
exist: /home/id3/junk/favicon.ico
[Sat Jan 19 16:40:12 2008] [error] [client 82.154.53.56] File does not
exist: /home/id3/junk/missing.html
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] do.cgi:9
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] :
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151]
uninitialized constant Mofo
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] (
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] NameError
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] )
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] Premature
end of script headers: do.cgi
[Sat Jan 19 16:41:05 2008] [error] [client 82.155.224.151] File does
not exist: /home/id3/junk/internal_error.html
[Sat Jan 19 16:41:11 2008] [error] [client 82.155.224.151] do.cgi:9:
uninitialized constant Mofo (NameError)
[Sat Jan 19 16:41:11 2008] [error] [client 82.155.224.151] Premature
end of script headers: do.cgi
[Sat Jan 19 16:41:11 2008] [error] [client 82.155.224.151] File does
not exist: /home/id3/junk/internal_error.html


I thought this wasn't implemented since when I reached the code in
line 133 (microformat.rb) there was an integer.


Another suggestion that would be useful was to add a to_s to each
microformat and a to_html (i'm currently doing that by hand for
hCard). I believe it would be useful in a lot of situations like mine.

Thanks

Alcides Fonseca

(BTW, I'm working on this: http://junk.ideias3.com/hCard/?url=http://alcides.ideias3.com/
)


On Jan 20, 12:03 am, "Chris Wanstrath" <ch...@ozmm.org> wrote:

Chris Wanstrath

unread,
Jan 19, 2008, 8:22:16 PM1/19/08
to mof...@googlegroups.com
Make sure you have the 0.2.10 gem. Line 133 in this gem is inside
#find_every, not #build_doc (which handles the timeout).

If you submit a patch to the Lighthouse for your other feature
requests, I can add them in:

http://err.lighthouseapp.com/projects/466-plugins/tickets/new

Unfortunately I don't have much time to work on poor Mofo these days,
but I'll try to apply patches if they're tested.

Cheers,
Chris

On 1/19/08, Alcides Fonseca <alcides...@gmail.com> wrote:
>

Reply all
Reply to author
Forward
0 new messages