Professional Web Applications Themes

YAML Aborting with large data set? - Ruby

Hi all, I have a large doent in yaml which I can't load or dump using YAML in ruby because it segfaults. I have searched the archives and I wonder if this error is similar to that described in the ruby-talk thread "Syck 0.35 + YAML.rb 0.60 -- the 1st stable release". However in that thread I believe that multi-threaded scripts were the main cause for concern... This bugs out on all of my development machines: [martindorfl dev]$ ruby -v ruby 1.8.1 (2003-12-25) [i686-linux] [martindorfl dev]$ irb irb(main):001:0> require "yaml" => true irb(main):002:0> string = "hello world" * 2000 => ...

  1. #1

    Default YAML Aborting with large data set?


    Hi all,

    I have a large doent in yaml which I can't load or dump using YAML in ruby
    because it segfaults. I have searched the archives and I wonder if this
    error is similar to that described in the ruby-talk thread "Syck 0.35 +
    YAML.rb 0.60 -- the 1st stable release". However in that thread I believe
    that multi-threaded scripts were the main cause for concern...

    This bugs out on all of my development machines:

    [martindorfl dev]$ ruby -v
    ruby 1.8.1 (2003-12-25) [i686-linux]

    [martindorfl dev]$ irb
    irb(main):001:0> require "yaml"
    => true
    irb(main):002:0> string = "hello world" * 2000
    => "hello worldhello worldhello worldhello worldhello wo...... etc"
    irb(main):003:0> data = string.to_yaml
    /usr/local/lib/ruby/1.8/yaml/rubytypes.rb:315: [BUG] Segmentation fault
    ruby 1.8.1 (2003-12-25) [i686-linux]

    Aborted
    [martindorfl dev]$

    Can somebody else confirm that this is reproducable?

    As I mentioned above - the doent that I want to convert to/from YAML is
    large. Is there a size limitation that I am unaware of with the current yaml
    implementation?

    Cheers,
    Martin

    --
    Martin Hart
    Arnclan Limited
    53 Union Street
    Dunstable, Beds
    LU6 1EX
    http://www.arnclanit.com




    Martin Guest

  2. #2

    Default Re: YAML Aborting with large data set?

    >>>>> "M" == Martin Hart <com> writes:

    M> I have a large doent in yaml which I can't load or dump using YAML in ruby
    M> because it segfaults. I have searched the archives and I wonder if this
    M> error is similar to that described in the ruby-talk thread "Syck 0.35 +
    M> YAML.rb 0.60 -- the 1st stable release". However in that thread I believe
    M> that multi-threaded scripts were the main cause for concern...

    Best to use the CVS version of ruby, and see if you can reproduce the
    problem.


    Guy Decoux





    ts Guest

  3. #3

    Default Re: YAML Aborting with large data set?

    On Saturday 21 February 2004 16:36, ts wrote: 

    thanks for the quick response. Indeed ruby 1.9.0 does not have this problem.

    Cheers,
    Martin




    Martin Guest

  4. #4

    Default Re: YAML Aborting with large data set?

    On Sunday, February 22, 2004, 3:18:31 AM, Martin wrote:

     
     

    The code you gave worked for me

    ruby 1.8.1 (2004-01-08) [i386-cygwin]

    It was happy with a multiplier of 20000 as well.

    Cheers,
    Gavin




    Gavin Guest

Similar Threads

  1. reading array data back into perl with YAML
    By bijanmossadeghi@yahoo.com in forum PERL Modules
    Replies: 2
    Last Post: December 2nd, 09:53 PM
  2. Replies: 2
    Last Post: December 4th, 04:20 PM
  3. Aborting a process
    By DarkVipr in forum Macromedia Fireworks
    Replies: 8
    Last Post: November 3rd, 07:40 PM
  4. Aborting a _Click event?
    By Wayne MJ in forum ASP.NET General
    Replies: 3
    Last Post: July 29th, 05:37 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139