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

Explicitly loading active_record prevents an error using sidekiqswarm #420

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

adamcooper
Copy link

Explicitly require active_record to prevent loading error using sidekiqswarm:

$> sidekiqswarm
[swarm] Preloading Bundler groups ["default"]
bundler: failed to load command: sidekiqswarm (/Users/pcreux/.rbenv/versions/2.6.6/bin/sidekiqswarm) NameError: uninitialized constant Scenic::SchemaDumper::ActiveRecord
/Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic/schema_dumper.rb:30:in <module:SchemaDumper>' /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic/schema_dumper.rb:5:in module:Scenic'
/Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic/schema_dumper.rb:3:in <top (required)>' /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic.rb:6:in <top (required)>'
/Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:81:in require' /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:81:in block (2 levels) in require'
/Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:76:in each' /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:76:in block in require'
/Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:65:in each' /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:65:in require'
/Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler.rb:114:in require' /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/sidekiq-ent-2.2.0/bin/sidekiqswarm:40:in <top (required)>'
/Users/pcreux/.rbenv/versions/2.6.6/bin/sidekiqswarm:23:in load' /Users/pcreux/.rbenv/versions/2.6.6/bin/sidekiqswarm:23:in <top (required)>'

... to prevent loading error using sidekiqswarm:

$> sidekiqswarm
[swarm] Preloading Bundler groups ["default"]
bundler: failed to load command: sidekiqswarm (/Users/pcreux/.rbenv/versions/2.6.6/bin/sidekiqswarm)
NameError: uninitialized constant Scenic::SchemaDumper::ActiveRecord
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic/schema_dumper.rb:30:in `<module:SchemaDumper>'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic/schema_dumper.rb:5:in `<module:Scenic>'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic/schema_dumper.rb:3:in `<top (required)>'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/scenic-1.5.4/lib/scenic.rb:6:in `<top (required)>'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:81:in `require'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:81:in `block (2 levels) in require'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:76:in `each'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:76:in `block in require'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:65:in `each'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler/runtime.rb:65:in `require'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/bundler-1.17.3/lib/bundler.rb:114:in `require'
  /Users/pcreux/.rbenv/versions/2.6.6/lib/ruby/gems/2.6.0/gems/sidekiq-ent-2.2.0/bin/sidekiqswarm:40:in `<top (required)>'
  /Users/pcreux/.rbenv/versions/2.6.6/bin/sidekiqswarm:23:in `load'
  /Users/pcreux/.rbenv/versions/2.6.6/bin/sidekiqswarm:23:in `<top (required)>'
@adamcooper adamcooper changed the title Update scenic gem to latest version and load active_record Explicitly loading active_record prevents an error using sidekiqswarm Jul 9, 2024
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

Successfully merging this pull request may close these issues.

2 participants