AWS-S3宝石,除非定义? @@ {:instance_writer =>真} [英] aws-s3 gem unless defined? @@{:instance_writer=>true}

查看:150
本文介绍了AWS-S3宝石,除非定义? @@ {:instance_writer =>真}的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图整合 AWS-S3 宝石和Rails的最新版本(4.1 .0),并启动服务器时,我收到此错误:

I am trying to integrate the aws-s3 gem with the latest version of Rails (4.1.0), and when starting the server I receive this error:

aws-s3-0.6.3/lib/aws/s3/extensions.rb:223:in `class_eval': ///.rvm/gems/ruby-1.9.3-p385/gems/aws-s3-0.6.3/lib/aws/s3/extensions.rb:223: syntax error, unexpected $undefined (SyntaxError) unless defined? @@{:instance_writer=>true}

有没有人有什么想法?

Has anyone got any ideas?

创业板的大部分尚未更新超过两年,所以我认为它可能最终会过时。

The bulk of the gem has not been updated for over two years so I am thinking that it may finally be out of date.

推荐答案

在Rails 4.1的错误发生,因为 cattr_attribute 从模块中删除。

In Rails 4.1 the bug is happening because cattr_attribute was removed from Module.

一个短期看在GitHub上的问题说,该项目已被放弃。

A short look at the issues in github say that the project has been abandoned.

这拉的请求是为了解决这个问题: https://github.com/marcel/aws-s3/pull/95

This pull request was to fix the issue: https://github.com/marcel/aws-s3/pull/95

您可能需要使用叉子一个像 https://github.com/bartoszkopinski/aws-s3 ,这解决了问题,或改变宝石的 https://github.com / AWS / AWS-SDK-红宝石

You may want to use one of forks like https://github.com/bartoszkopinski/aws-s3, that fixes the issue, or change the gem to the https://github.com/aws/aws-sdk-ruby.

这篇关于AWS-S3宝石,除非定义? @@ {:instance_writer =>真}的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆