Development QoL changes and bug fixes #159
Merged
Merged
Conversation
- Concentrate all the rails-* commands under a single bin/rails - let bin/rspec be less noisy with the sync
Short and sweet.
Allow going the other direction when coming back to solidus from Stripe.
kennyadsl
approved these changes
Feb 7, 2023
kennyadsl
left a comment
Member
There was a problem hiding this comment.
Left a small comment but all commits make sense to me. Thanks!
| @@ -1,2 +1,2 @@ | |||
| web: unset PORT && bin/rails-sandbox server | |||
| installer: bin/rails-sandbox g solidus_stripe:install --force --watch | |||
| web: unset PORT && env RUBY_DEBUG_OPEN=true bin/rails-sandbox server | |||
Member
There was a problem hiding this comment.
What about a comment with usage instructions here?
Member
Author
There was a problem hiding this comment.
Great call, added instructions to the readme under Development so it's even more visible.
To attach just use `rdbg --attach`.
In every place we used `client.request` we always ignored the response object.
Otherwise the following error will be raised when using generators from the rails engine: /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_core-3.3.0/lib/spree/core.rb:9:in `require': cannot load such file -- active_storage/engine (LoadError) from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_core-3.3.0/lib/spree/core.rb:9:in `<top (required)>' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_core-3.3.0/lib/spree_core.rb:3:in `require' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_core-3.3.0/lib/spree_core.rb:3:in `<top (required)>' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_core-3.3.0/lib/solidus_core.rb:3:in `require' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/solidus_core-3.3.0/lib/solidus_core.rb:3:in `<top (required)>' from /Users/elia/Code/Nebulab/solidus_stripe/lib/solidus_stripe/engine.rb:3:in `require' from /Users/elia/Code/Nebulab/solidus_stripe/lib/solidus_stripe/engine.rb:3:in `<top (required)>' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/command/actions.rb:19:in `require' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/command/actions.rb:19:in `require_application!' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/command/actions.rb:14:in `require_application_and_environment!' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/commands/generate/generate_command.rb:21:in `perform' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/thor-1.2.1/lib/thor/command.rb:27:in `run' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/thor-1.2.1/lib/thor/invocation.rb:127:in `invoke_command' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/thor-1.2.1/lib/thor.rb:392:in `dispatch' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/command/base.rb:87:in `perform' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/command.rb:48:in `invoke' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/commands.rb:18:in `<top (required)>' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/engine/commands.rb:9:in `require' from /Users/elia/.asdf/installs/ruby/3.1.1/lib/ruby/gems/3.1.0/gems/railties-7.0.4.2/lib/rails/engine/commands.rb:9:in `<top (required)>' from /Users/elia/Code/Nebulab/solidus_stripe/bin//rails:35:in `require' from /Users/elia/Code/Nebulab/solidus_stripe/bin//rails:35:in `<main>'
The solidus code will always provide the "originator" option.
elia
force-pushed
the
elia/misc-fixes
branch
2 times, most recently
from
February 8, 2023 14:38
62ba8b4 to
208d89a
Compare
waiting-for-dev
approved these changes
Feb 9, 2023
| order = Spree::TestingSupport::OrderWalkthrough.up_to(:delivery, user: nil) | ||
| visit '/' | ||
|
|
||
| allow_any_instance_of( # rubocop:disable RSpec/AnyInstance |
Contributor
There was a problem hiding this comment.
For future reference, it looks like testing a guest order requires a lot of preparation. Probably it'd be nice to extract that into the testing support in core at some point.
The latest starter frontend requires the JS support provided in a vanilla rails installation. Other options are being removed that are not strictly necessary to build the dummy app. The rails version is now taken from the gemspec's bundle.
elia
force-pushed
the
elia/misc-fixes
branch
3 times, most recently
from
February 9, 2023 15:04
a83995b to
c6d9f9f
Compare
Update versions and stop using the deprecated cron option for scheduled runs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A mixed bag, mostly development QoL and refactoring.
Checklist
Check out our PR guidelines for more details.
The following are mandatory for all PRs:
The following are not always needed: