【发布时间】:2025-12-12 03:35:01
【问题描述】:
我有一个在 localhost 和 heroku 中工作的应用程序。上次我将新版本推送到 heroku 时,我在 heroku db:migrate 期间遇到了错误,并且做了 heroku db:push,一切正常。
执行应用程序时出现以下错误。 /app/.bundle/gems/ruby/1.9.1/gems/aws-s3-0.6.2/lib/aws/s3/extensions.rb:206:in `const_missing_from_s3_library': 未初始化的常量 AnswersController::Authentication (NameError)
这里是相关代码
class AnswersController < ApplicationController
include Authentication
...
Authentication是lib中定义的一个模块:
# encoding: utf-8
require 'base64'
require 'openssl'
module Authentication
...
它在 localhost 中工作,但在 heroku 中没有。 有什么帮助吗?? 谢谢
【问题讨论】:
标签: ruby-on-rails-3 authentication module heroku