This works when I try it in MRI. But this is what happens in Macruby. Is there a workaround? $ macirb -f irb(main):003:0> require 'aws/s3' => true irb(main):006:0> AWS::S3::Base.establish_connection!( irb(main):007:0> :access_key_id => ACCESS_KEY, irb(main):008:0> :secret_access_key => SECRET_ACCESS_KEY irb(main):009:0> ) => #<AWS::S3::Connection:0x40043ed60 @options={:server=>" s3.amazonaws.com", :port=>80, :access_key_id=>"XXXX", :secret_access_key=>"XXXX"} @access_key_id="XXXX" @secret_access_key="XXXX" @http=#<Net::HTTP s3.amazonaws.com:80 open=false>> irb(main):010:0> AWS::S3::Service.buckets NameError: `@policy:' is not allowed as an instance variable name /Users/jeremysmith/.rvm/gems/macruby-0.10/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:142:in `expirable_memoize:' /Users/jeremysmith/.rvm/gems/macruby-0.10/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:176:in `policy:'
I haven’t used this library on MacRuby, so unless someone else knows of a workaround the only solution is to fix it. It would be great if you could reduce the actual problem to a few lines of code and file a ticket, even if there's a workaround :) Eloy On 25 aug. 2011, at 21:25, Jeremy Smith wrote:
This works when I try it in MRI. But this is what happens in Macruby. Is there a workaround?
$ macirb -f irb(main):003:0> require 'aws/s3' => true irb(main):006:0> AWS::S3::Base.establish_connection!( irb(main):007:0> :access_key_id => ACCESS_KEY, irb(main):008:0> :secret_access_key => SECRET_ACCESS_KEY irb(main):009:0> ) => #<AWS::S3::Connection:0x40043ed60 @options={:server=>"s3.amazonaws.com", :port=>80, :access_key_id=>"XXXX", :secret_access_key=>"XXXX"} @access_key_id="XXXX" @secret_access_key="XXXX" @http=#<Net::HTTP s3.amazonaws.com:80 open=false>> irb(main):010:0> AWS::S3::Service.buckets NameError: `@policy:' is not allowed as an instance variable name /Users/jeremysmith/.rvm/gems/macruby-0.10/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:142:in `expirable_memoize:' /Users/jeremysmith/.rvm/gems/macruby-0.10/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:176:in `policy:' _______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
Actually, googling did reveal some Objective-C code for S3, which is a possible workaround. HTH On 25 aug. 2011, at 21:25, Jeremy Smith wrote:
This works when I try it in MRI. But this is what happens in Macruby. Is there a workaround?
$ macirb -f irb(main):003:0> require 'aws/s3' => true irb(main):006:0> AWS::S3::Base.establish_connection!( irb(main):007:0> :access_key_id => ACCESS_KEY irb(main):008:0> :secret_access_key => SECRET_ACCESS_KEY irb(main):009:0> ) => #<AWS::S3::Connection:0x40043ed60 @options={:server=>"s3.amazonaws.com", :port=>80, :access_key_id=>"XXXX", :secret_access_key=>"XXXX"} @access_key_id="XXXX" @secret_access_key="XXXX" @http=#<Net::HTTP s3.amazonaws.com:80 open=false>> irb(main):010:0> AWS::S3::Service.buckets NameError: `@policy:' is not allowed as an instance variable name /Users/jeremysmith/.rvm/gems/macruby-0.10/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:142:in `expirable_memoize:' /Users/jeremysmith/.rvm/gems/macruby-0.10/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:176:in `policy:' _______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
There's a library for iOS, which should be able to run without too much effort on mac: http://aws.amazon.com/sdkforios/ hth, Rolando On Sat, Aug 27, 2011 at 10:43 AM, Eloy Duran <eloy.de.enige@gmail.com> wrote:
Actually, googling did reveal some Objective-C code for S3, which is a possible workaround. HTH -- Rolando Abarca M. Phones: +1 (415) 655-1041 +56 (2) 581-4591
participants (3)
-
Eloy Duran
-
Jeremy Smith
-
Rolando Abarca