Could you please file a bug report? I'll try to look into it ASAP. Thanks, - Matt On Sun, Nov 1, 2009 at 9:42 AM, Gaz Liddon <gaz@gazaxian.com> wrote:
Hiya :)
I've a problem using Drb and get a problem I don't get if I use bog standard ruby 1.8
My client and server code is below.
The server works fine but if I try and invoke any method on the client from the server I get this error:
core:in `open:': can't convert NSMutableDictionary into String (TypeError) from /Library/Frameworks/MacRuby.framework/Versions/0.5/usr/lib/ruby/1.9.0/drb/drb.rb:1196:in `initialize:' from core:in `__new__:' from /Library/Frameworks/MacRuby.framework/Versions/0.5/usr/lib/ruby/1.9.0/drb/drb.rb:1163:in `open:' from /Library/Frameworks/MacRuby.framework/Versions/0.5/usr/lib/ruby/1.9.0/drb/drb.rb:1109:in `with_friend:' from /Library/Frameworks/MacRuby.framework/Versions/0.5/usr/lib/ruby/1.9.0/drb/drb.rb:1091:in `method_missing:' from /Users/garyliddon/drbtest.rb:1:in `<main>'
Any help super gratefully received :)
gaz
*SERVER CODE* require 'drb'
class Incrementer
def initialize @value = 0 end
def increment @value += 1 end
end
service = DRb.start_service("druby://localhost:4242", Incrementer.new) print "service started on port 4242\n" DRb.thread.join
* * *CLIENT CODE* require 'drb' DRb.start_service server = DRbObject.new_with_uri('druby://localhost:4242') p server.increment #this is what causes the error
_______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel