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

warning: already initialized constant Merit::AppBadgeRules #173

Closed
emaillenin opened this issue Jun 2, 2014 · 29 comments · Fixed by #282 or #313
Closed

warning: already initialized constant Merit::AppBadgeRules #173

emaillenin opened this issue Jun 2, 2014 · 29 comments · Fixed by #282 or #313

Comments

@emaillenin
Copy link

I get the following error while initializing rails console/server while using Merit ~> 2.0. The same warning existing since Merit 2.0.0.

~/project (master) ⚡ rails c
/Library/Ruby/Gems/2.0.0/gems/merit-2.1.1/lib/merit.rb:83: warning: already initialized constant Merit::AppBadgeRules
/Library/Ruby/Gems/2.0.0/gems/merit-2.1.1/lib/merit.rb:83: warning: previous definition of AppBadgeRules was here
/Library/Ruby/Gems/2.0.0/gems/merit-2.1.1/lib/merit.rb:84: warning: already initialized constant Merit::AppPointRules
/Library/Ruby/Gems/2.0.0/gems/merit-2.1.1/lib/merit.rb:84: warning: previous definition of AppPointRules was here
Loading development environment (Rails 4.0.0)
@emaillenin
Copy link
Author

This is due to explicit loading by Rails. To fix this, change:

          Merit::AppBadgeRules = Merit::BadgeRules.new.defined_rules
          Merit::AppPointRules = Merit::PointRules.new.defined_rules

to

          Merit::AppBadgeRules ||= Merit::BadgeRules.new.defined_rules
          Merit::AppPointRules ||= Merit::PointRules.new.defined_rules

@tute
Copy link
Member

tute commented Jun 2, 2014

That's weird, I don't get that error. Why would it be loading twice? Your proposed fix would affect code reloading in development: if you edit rules and not restart the server, merit won't see them. Can you please post your Gemfile?

@emaillenin
Copy link
Author

Hi @tute, my Gemfile below:

source 'https://rubygems.org'

# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.0.0'

# Use mysql as the database for Active Record
gem 'mysql2'

gem 'haml'

gem 'haml-rails'

gem 'paperclip'

# Use SCSS for stylesheets
# gem 'sass-rails', '~> 4.0.0'

# Use Uglifier as compressor for JavaScript assets
# gem 'uglifier', '>= 1.3.0'

gem 'font-awesome-rails'

# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby

# Use jquery as the JavaScript library
gem 'jquery-rails'

# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
gem 'turbolinks'

gem 'jquery-turbolinks'

gem 'jquery-ui-rails'

# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 1.2'

gem 'devise'

# https://github.com/justinfrench/formtastic

gem 'formtastic'

# https://github.com/plataformatec/simple_form
# Wow I am using two form libraries for my project

gem 'simple_form'

gem 'merit', '~> 2.0'

gem 'icalendar'

gem 'will_paginate', '~> 3.0.5'

gem 'rails-api'

gem 'piwik_analytics', '~> 1.0'

group :doc do
  # bundle exec rake doc:rails generates the API under doc/api.
  gem 'sdoc', require: false
end

# Gems used only for assets and not required
# in production environments by default.
group :assets do
  gem 'sass-rails',   "~> 4.0.0"
  gem 'coffee-rails', "~> 4.0.0"
  gem 'uglifier', '>= 1.3.0'
end

ruby '2.0.0'

# Use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.0.0'

# Use unicorn as the app server
# gem 'unicorn'

# Use Capistrano for deployment
# gem 'capistrano', group: :development

# Use debugger
# gem 'debugger', group: [:development, :test]

@tute
Copy link
Member

tute commented Jun 2, 2014

Thanks for your input. I'll need a failing application in Github to reproduce/debug though.

@tute
Copy link
Member

tute commented Jun 5, 2014

@emaillenin how can I replicate this error?

@emaillenin
Copy link
Author

@tute - Can you try creating an app with all the gems I listed above?
Thanks,
Lenin

@tute
Copy link
Member

tute commented Jun 6, 2014

From the Gemfile I can recreate apps that don't show that behavior. What you described could be caused by application code, exact Ruby version (which patch level?), etc.
Failing application or even a failing test will allow me to see the problem easier. As stated in https://github.com/norman/yourbugreportneedsmore.info/blob/master/index.html/, reproducibility is key. Thank you!

@tute
Copy link
Member

tute commented Jun 24, 2014

Closing for now until we can reproduce. Thanks!

@tute tute closed this as completed Jun 24, 2014
@emaillenin
Copy link
Author

Was looking at this issue again. I kept a binding.pry in lib/merit.rb

      ActiveSupport.on_load(:action_controller) do
        begin
          # Load app rules on boot up
          binding.pry
          Merit::AppBadgeRules = Merit::BadgeRules.new.defined_rules
          Merit::AppPointRules = Merit::PointRules.new.defined_rules
          include Merit::ControllerExtensions
        rescue NameError => e
          # Trap NameError if installing/generating files
          raise e unless e.to_s =~ /uninitialized constant Merit::BadgeRules/
        end
      end

And started the rails server. I hit this breakpoint twice. But pry-backtrace reveals the same trace for the both the times.

/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/merit-2.1.1/lib/merit.rb:83:in `block (2 levels) in <class:Engine>'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/lazy_load_hooks.rb:38:in `instance_eval'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/lazy_load_hooks.rb:38:in `execute_hook'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/lazy_load_hooks.rb:28:in `block in on_load'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/lazy_load_hooks.rb:27:in `each'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/lazy_load_hooks.rb:27:in `on_load'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/merit-2.1.1/lib/merit.rb:80:in `block in <class:Engine>'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/initializable.rb:30:in `instance_exec'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/initializable.rb:30:in `run'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/initializable.rb:55:in `block in run_initializers'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:226:in `block in tsort_each'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:348:in `block (2 levels) in each_strongly_connected_component'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:427:in `each_strongly_connected_component_from'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:347:in `block in each_strongly_connected_component'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:345:in `each'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:345:in `call'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:345:in `each_strongly_connected_component'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:224:in `tsort_each'
/Users/leninraj/.rvm/rubies/ruby-2.1.2/lib/ruby/2.1.0/tsort.rb:205:in `tsort_each'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/initializable.rb:54:in `run_initializers'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/application.rb:300:in `initialize!'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/railtie.rb:194:in `public_send'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/railtie.rb:194:in `method_missing'
/Users/leninraj/Dropbox/Projects/duggout/duggout/config/environment.rb:5:in `<top (required)>'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:247:in `require'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:247:in `block in require'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:232:in `load_dependency'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/activesupport-4.1.4/lib/active_support/dependencies.rb:247:in `require'
/Users/leninraj/Dropbox/Projects/duggout/duggout/config.ru:3:in `block in <main>'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/builder.rb:55:in `instance_eval'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/builder.rb:55:in `initialize'
/Users/leninraj/Dropbox/Projects/duggout/duggout/config.ru:in `new'
/Users/leninraj/Dropbox/Projects/duggout/duggout/config.ru:in `<main>'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/builder.rb:49:in `eval'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/builder.rb:49:in `new_from_string'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/builder.rb:40:in `parse_file'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/server.rb:277:in `build_app_and_options_from_config'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/server.rb:199:in `app'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/server.rb:50:in `app'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/rack-1.5.2/lib/rack/server.rb:314:in `wrapped_app'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/server.rb:130:in `log_to_stdout'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/server.rb:67:in `start'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/commands_tasks.rb:81:in `block in server'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/commands_tasks.rb:76:in `tap'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/commands_tasks.rb:76:in `server'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands/commands_tasks.rb:40:in `run_command!'
/Users/leninraj/.rvm/gems/ruby-2.1.2/gems/railties-4.1.4/lib/rails/commands.rb:17:in `<top (required)>'
bin/rails:4:in `require'
bin/rails:4:in `<main>'

Can you spot anything weird in the trace?

@beydogan
Copy link

I'm getting the same warning message.

merit (2.3.2)
rails (4.1.6)
rails-api (0.4.0)

@SunnyTam
Copy link

getting same warning.

@domness
Copy link

domness commented Feb 17, 2016

Getting the same warning as well:

gems/merit-2.3.2/lib/merit.rb:88: warning: already initialized constant Merit::AppBadgeRules
gems/merit-2.3.2/lib/merit.rb:88: warning: previous definition of AppBadgeRules was here
gems/merit-2.3.2/lib/merit.rb:89: warning: already initialized constant Merit::AppPointRules
gems/merit-2.3.2/lib/merit.rb:89: warning: previous definition of AppPointRules was here

Using:

  • Ruby 2.2.3
  • Rails 4.2.5

@tute
Copy link
Member

tute commented Feb 24, 2016

I wonder why would we hit ActiveSupport.on_load(:action_controller) more than once on server initialization. @eileencodes, can you spot why is this happening? Thank you very much!

@zokioki
Copy link

zokioki commented Mar 14, 2016

I'm seeing these warnings as well:

  • Merit 2.3.3
  • Ruby 2.3.0
  • Rails 5.0.0.beta3

@tute tute reopened this Mar 14, 2016
@pacMakaveli
Copy link

pacMakaveli commented May 25, 2016

In reply to @zokioki which has a very similar setup to mine. I'm not getting this problem

  • Merit 2.3.4
  • Ruby 2.3.1-p112
  • Rails 5.0.0.rc1

There is a problem with Ruby 2.3.0, so you might want to update to 2.3.1
e2/ruby_dep#8 (comment)

@zokioki
Copy link

zokioki commented May 28, 2016

@pacMakaveli I've updated Ruby, Rails and Merit to exactly match the versions in your setup - the warnings persist for me.

@pacMakaveli
Copy link

@zokioki Did you update you bin/* ?
Rails 5 introduced a new way of loading the files. http://railsdiff.org/5.0.0.beta3/5.0.0.rc1

Be sure to check config.ru , bin/* and application.rb

@zokioki
Copy link

zokioki commented May 30, 2016

@pacMakaveli Updating the code highlighted in that railsdiff for the rc1 release did the trick for me. Thank you! 👍

@jrasanen
Copy link

jrasanen commented Jul 14, 2016

Changing the highlighted rails diffs code didn't work for me (rake rails:upgrade changed most of those for me already), I still keep getting the same errors, @emaillenin's fix would work for me, my stacktrace is nearly identical when attaching binding.pry.

Trace

/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/merit-2.3.4/lib/merit.rb:87:in `block (2 levels) in <class:Engine>'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0/lib/active_support/lazy_load_hooks.rb:38:in `instance_eval'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0/lib/active_support/lazy_load_hooks.rb:38:in `execute_hook'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0/lib/active_support/lazy_load_hooks.rb:28:in `block in on_load'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0/lib/active_support/lazy_load_hooks.rb:27:in `each'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/activesupport-5.0.0/lib/active_support/lazy_load_hooks.rb:27:in `on_load'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/merit-2.3.4/lib/merit.rb:85:in `block in <class:Engine>'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/initializable.rb:30:in `instance_exec'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/initializable.rb:30:in `run'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/initializable.rb:55:in `block in run_initializers'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:228:in `block in tsort_each'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:431:in `each_strongly_connected_component_from'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:349:in `block in each_strongly_connected_component'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:347:in `each'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:347:in `call'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:347:in `each_strongly_connected_component'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:226:in `tsort_each'
/Users/jrasanen/.rvm/rubies/ruby-2.3.1/lib/ruby/2.3.0/tsort.rb:205:in `tsort_each'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/initializable.rb:54:in `run_initializers'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/application.rb:352:in `initialize!'
/Users/jrasanen/Development/ror/stream/s/config/environment.rb:5:in `<top (required)>'
/Users/jrasanen/Development/ror/stream/s/config.ru:2:in `require_relative'
/Users/jrasanen/Development/ror/stream/s/config.ru:2:in `block in <main>'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/builder.rb:55:in `instance_eval'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/builder.rb:55:in `initialize'
/Users/jrasanen/Development/ror/stream/s/config.ru:in `new'
/Users/jrasanen/Development/ror/stream/s/config.ru:in `<main>'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/builder.rb:49:in `eval'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/builder.rb:49:in `new_from_string'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/builder.rb:40:in `parse_file'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/server.rb:318:in `build_app_and_options_from_config'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/server.rb:218:in `app'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/server.rb:59:in `app'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/rack-2.0.1/lib/rack/server.rb:353:in `wrapped_app'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/server.rb:124:in `log_to_stdout'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/server.rb:77:in `start'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/commands_tasks.rb:90:in `block in server'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/commands_tasks.rb:85:in `tap'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/commands_tasks.rb:85:in `server'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands/commands_tasks.rb:49:in `run_command!'
/Users/jrasanen/.rvm/gems/ruby-2.3.1/gems/railties-5.0.0/lib/rails/commands.rb:18:in `<top (required)>'
bin/rails:4:in `require'
bin/rails:4:in `<top (required)>'

config.ru

# This file is used by Rack-based servers to start the application.
require_relative 'config/environment'

run Rails.application

application.rb

require_relative 'boot'

require 'rails/all'

# Require the gems listed in Gemfile, including any gems
# you've limited to :test, :development, or :production.
Bundler.require(*Rails.groups)

module S
  class Application < Rails::Application
    # redacted~
  end
end

environment.rb

# Load the Rails application.
require_relative 'application'

# Initialize the Rails application.
Rails.application.initialize!

bin/rails

#!/usr/bin/env ruby
APP_PATH = File.expand_path('../config/application', __dir__)
require_relative '../config/boot'
require 'rails/commands'

bigredpen added a commit to bigredpen/merit that referenced this issue Jul 30, 2016
jnettome added a commit to jnettome/merit that referenced this issue Jul 24, 2017
applying the suggested solution on merit-gem#173
@redtachyons
Copy link

@zokioki Can you please explain what exactly is changed? I am still getting this error

@redtachyons
Copy link

ActiveSupport.on_load(:action_controller) is getting called twice , So I don't think this issue is specific to this gem

@redtachyons
Copy link

After digging more I found the cause, rails calls ActiveSupport.run_load_hooks(:action_controller, self) From two places, one from ActionController::Base and other from ActionController::API, If your app or the gems you use load both, then action_controller load callback will load twice

  1. https://github.com/rails/rails/blob/5-1-stable/actionpack/lib/action_controller/base.rb#L271

  2. https://github.com/rails/rails/blob/5-1-stable/actionpack/lib/action_controller/api.rb#L145

@redtachyons
Copy link

@tute opened an issue here please have a look

@tute
Copy link
Member

tute commented Nov 3, 2017

Thank you @redtachyons! It looks like the :run_once option would fix our case, as Rafael mentions in rails/rails#31041 (comment); we don't care about the type of controller on this part of merit. That's introduced in rails/rails#30045 though, already for Rails 5.1? How does Rails 5 react if we try to use the option but it doesn't yet exist?

Thank you again!

@redtachyons
Copy link

Thanks for the reply, I tried https://gist.github.com/redtachyons/568e0f79804d80f90de12f73353a86a2 this snippet with rails >5.0 & < 5.1.4, it just silently ignored that extra parameter. So adding run_once will fix the issue for newer version of rails

@tute
Copy link
Member

tute commented Nov 3, 2017

Sounds like finally we have a proper solution! Mind sending in a PR?

@redtachyons
Copy link

Sure

@tute
Copy link
Member

tute commented Nov 3, 2017

Closing in favor of #282. Thank you, @redtachyons! ❤️

@tute tute closed this as completed Nov 3, 2017
redtachyons added a commit to tachyons/merit that referenced this issue Nov 3, 2017
…ler::Base and ActionController::API.

Rails [introduced](rails/rails#30045) `has_one` option to limit executions to one

This will fix merit-gem#173 for rails 5.1.4 and above
redtachyons pushed a commit to tachyons/merit that referenced this issue Nov 3, 2017
Rails execute `action_controller` onload hooks for Both ActionController::Base and ActionController::API.

Rails [introduced](rails/rails#30045) `has_one` option to limit executions to one

This will fix merit-gem#173 for rails 5.1.4 and above
xofred added a commit to xofred/merit that referenced this issue Nov 28, 2017
@natanio
Copy link
Contributor

natanio commented Jan 14, 2022

I'm seeing this in our app in the console output of rails jobs:work using DelayedJob.

merit (4.0.2)
ruby 2.7.4p191
rails (6.1.4.4)

/merit/lib/merit.rb:70: warning: already initialized constant Merit::AppPointRules
/merit/lib/merit.rb:70: warning: previous definition of AppPointRules was here

Adjusting this locally has removed seeing the above warnings: #173 (comment).

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