Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed bundle exec rails app:update #67

Open
tmhr94 opened this issue Sep 12, 2022 · 2 comments

Comments

@tmhr94
Copy link

tmhr94 commented Sep 12, 2022

Hi, there.

Occurred an error uninitialized constant ApplicationHelper when executed bundle exec rails app:update.

Is there anyone who has the same error or knows anything to solve it?

An environment the error occurred is:

$ ruby -v
ruby 2.7.6p219
$ bin/rails version
Rails 7.0.4

rambulance (2.2.0)

Following stuff are that I've done to find out the solution of an error uninitialized constant ApplicationHelper.

  1. Checked Traceback and investigated the gems called from it and found rambulance gem.
  2. Tried removing the gem 'rambulance' line from Gemfile and the error went away.
@tmhr94 tmhr94 changed the title Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed rambulance:install Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed rambulance:install Sep 12, 2022
@tmhr94 tmhr94 changed the title Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed rambulance:install Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed bin/rails active_storage:update Sep 13, 2022
@tmhr94 tmhr94 changed the title Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed bin/rails active_storage:update Occurred an error uninitialized constant ApplicationHelper on Rails 7.0.4 when executed bundle exec rails app:update Sep 13, 2022
@SaitoJP
Copy link

SaitoJP commented Feb 15, 2024

If you require it at the top of config/application.rb, it might work.

# FIXME: The process of requiring the exceptions_app from rambulance is being loaded at an unexpected timing? So we're requiring it manually.
# Problematic code section: https://github.com/yuki24/rambulance/blob/v3.0.0/lib/rambulance/railtie.rb#L5
require 'rambulance/exceptions_app'

@kohheepeace
Copy link

@SaitoJP Super thanks. you saved my life!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants