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

Cannot generate migration on /core #3249

Closed
kennyadsl opened this issue Jul 3, 2019 · 0 comments · Fixed by #3250
Closed

Cannot generate migration on /core #3249

kennyadsl opened this issue Jul 3, 2019 · 0 comments · Fixed by #3250
Labels
type:bug Error, flaw or fault

Comments

@kennyadsl
Copy link
Member

kennyadsl commented Jul 3, 2019

It's not currently possible to run rails commands on solidus (sub-)gems, due to a load error with Spree::Event::Subscriber not being loaded in time.

Solidus Version:
master

To Reproduce

> cd solidus
> cd core
> bundle exec rails generate migration add_fullname_to_spree_addresses fullname:string
Traceback (most recent call last):
	20: from script/rails:10:in `<main>'
	19: from script/rails:10:in `require'
	18: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/engine/commands.rb:9:in `<top (required)>'
	17: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/engine/commands.rb:9:in `require'
	16: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/commands.rb:18:in `<top (required)>'
	15: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/command.rb:46:in `invoke'
	14: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/command/base.rb:65:in `perform'
	13: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/thor-0.20.3/lib/thor.rb:387:in `dispatch'
	12: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/thor-0.20.3/lib/thor/invocation.rb:126:in `invoke_command'
	11: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/thor-0.20.3/lib/thor/command.rb:27:in `run'
	10: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/commands/generate/generate_command.rb:21:in `perform'
	 9: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/command/actions.rb:14:in `require_application_and_environment!'
	 8: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/command/actions.rb:19:in `require_application!'
	 7: from /Users/kennyadsl/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/gems/railties-5.2.3/lib/rails/command/actions.rb:19:in `require'
	 6: from /Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/core/engine.rb:4:in `<top (required)>'
	 5: from /Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/core/engine.rb:4:in `require'
	 4: from /Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/event/processors/mailer_processor.rb:3:in `<top (required)>'
	 3: from /Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/event/processors/mailer_processor.rb:4:in `<module:Spree>'
	 2: from /Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/event/processors/mailer_processor.rb:5:in `<module:Event>'
	 1: from /Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/event/processors/mailer_processor.rb:6:in `<module:Processors>'
/Users/kennyadsl/Code/nebulab/solidus/core/lib/spree/event/processors/mailer_processor.rb:7:in `<module:MailerProcessor>': uninitialized constant Spree::Event::Subscriber (NameError)

Additional context

I suspect this could be fixed by #3232, cc @elia.
Tried on that branch as well, it still happens.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Error, flaw or fault
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant