Okay, first of all I'm fairly new to Ruby, so it's quite possible
there's some essential concept I haven't grasped yet, but this strikes
me as extremely weird:

irb(main):001:0> require 'rexml/document'
true
irb(main):002:0> require 'pstore'
true
irb(main):003:0> doc = REXML::Document.new(File.open('server.xml'))
  [ lots of output, omitted for clarity ]
irb(main):004:0> ps = PStore.new('_db/server')
#<PStore:0x403ec7f4 @transaction=false, @abort=false,
@filename="_db/server">
irb(main):005:0> ps.transaction do
irb(main):006:1* ps['/'] = doc
irb(main):007:1> end
TypeError: singleton can't be dumped
        from /usr/local/lib/ruby-1.6.7/lib/ruby/1.6/pstore.rb:111:in \
            `dump'
        from /usr/local/lib/ruby-1.6.7/lib/ruby/1.6/pstore.rb:111:in \
            `transaction'
        from (irb):5

Now, I didn't believe for a moment that REXML::Document could actually
be a singleton, but by way of due diligence I did:

  $  grep -i singleton \
      /usr/local/lib/ruby-1.6.7/lib/ruby/site_ruby/1.6/rexml/*.rb

No hits.

So, can anybody hazard a guess as to what's going on here?

Hmm ... as I write this, it occurs to me this could be an irb bug. I'll
try it with plain ruby and see what happens. If you don't hear from
again in the next 10 minutes, assume that I got the same results again.

-- 
Matt Gushee
Englewood, Colorado, USA
mgushee / havenrock.com
http://www.havenrock.com/