Hpricot problems

Discussion in 'Ruby' started by Dean Kassmann, Feb 20, 2007.

  1. Has anyone successfully used Hpricot call multiple pages in the same
    ruby script:

    # begin code

    require 'hpricot'
    require 'open-uri'

    url = "http://ibm.com"
    N = 5

    page = nil

    for counter in (0..N)

    puts counter.to_s() + "> checking " + url
    page = Hpricot( open( url ) )
    sleep(2)

    end

    # end code

    I end up with the following error:

    >ruby test.rb

    0> checking http://ibm.com
    1> checking http://ibm.com
    2> checking http://ibm.com
    3> checking http://ibm.com
    c:/ruby/lib/ruby/gems/1.8/gems/hpricot-0.5-mswin32/lib/hpricot/parse.rb:44:
    [BUG] Segmentation fault
    ruby 1.8.2 (2004-12-25) [i386-mswin32]


    This application has requested the Runtime to terminate it in an unusual way.
    Please contact the application's support team for more information.

    Any pointers?
     
    Dean Kassmann, Feb 20, 2007
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Kenneth McDonald
    Replies:
    6
    Views:
    1,772
    Mark Thomas
    Dec 30, 2008
  2. Chris Gehlker

    Hpricot question

    Chris Gehlker, Jul 31, 2006, in forum: Ruby
    Replies:
    1
    Views:
    95
    Chris Gehlker
    Aug 1, 2006
  3. Chris Gehlker

    A simple Hpricot text setter

    Chris Gehlker, Aug 10, 2006, in forum: Ruby
    Replies:
    6
    Views:
    154
    Chris Gehlker
    Aug 16, 2006
  4. Sergio Ruiz

    mac - hpricot problems

    Sergio Ruiz, Sep 27, 2007, in forum: Ruby
    Replies:
    22
    Views:
    249
    mortee
    Oct 1, 2007
  5. -- --

    Hpricot parsing problems

    -- --, Feb 3, 2009, in forum: Ruby
    Replies:
    0
    Views:
    100
    -- --
    Feb 3, 2009
Loading...

Share This Page