This is the second pre-release of Solidus 3.0. Please let's give it a try and let us know if there are issues.
Preliminary Upgrade Guide
Follow these steps:
Update to the last released version of Solidus v2.11 (as of today, it is 2.11.5).
Be sure you have run the migrations installer with bin/rails railties:install:migrations and bin/rails db:migrate.
Run the update task with bin/rails solidus:upgrade:two_point_eleven.
Check your logs (either running your test suite or your production logs) and remove any deprecation warning. If you are using deprecated code, it is very likely that your application is not compliant with Solidus 3.0.
Update your Gemfile to use gem 'solidus', '3.0.0.rc2', run bundle install.
Common Problems
Spree::Image customization
Error:
~/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/activerecord-6.1.3/lib/active_record/dynamic_matchers.rb:22:in `method_missing': undefined method `has_one_attached' for #<Class:0x00007fc91f548d38>
Did you mean? has_attached_file (NoMethodError)
Cause
Spree::Image has now its default adapter to Active Storage, and you probably want to keep using the Paperclip adapter. This setting can be changed with:
Take care you don't have any customization of Spree::Image.attachment_definitions before setting that preference (even in other initializer files loaded before, eg config/initializers/paperclip.rb).
Solution
If you do, you'll see the error described above. To fix this, move the customization to a decorator, for example, if you have:
Removal of all code deprecated during the 2.x series
The main change in this major version is the removal of all deprecated code that
we introduced during the 2.x series. This means that if any code that was deprecated
is still being used, the application will break. Following the deprecation messages
in the application logs, it should be quite easy to spot what code needs to be changed.
The main things that could break a Solidus application are:
Paranoia gem has been replaced by Discard gem
All references to methods added to models by Paranoia will raise a NoMethodError exception now.
Some of those methods are:
Removed core support to first_name and last_name in Spree::Address
In Solidus v2.11, we added a name attribute to Spree::Address, which is being populated combining
first_name and last_name values every time a new address is added to the system. We also provided
a rake tasks to update all existing records in order to get applications ready for Solidus 3.0.
With this major version, name is the only supported attributes. first_name and last_name fields are already in the database
so if needed, a store can revert this change implementing their own logic.
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme
Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com):
- Update frequency (including time of day and day of week)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)
Updates the requirements on solidus_core to permit the latest version.
Release notes
Sourced from solidus_core's releases.
... (truncated)
Changelog
Sourced from solidus_core's changelog.
... (truncated)
Commits
3cc2d3e
Bump Solidus to 3.0.0.rc25368e8a
Merge pull request #3982 from nebulab/kennyadsl/uniform-update-task-outputa4d278c
Improve address name migration task output558fa4b
Merge pull request #3981 from solidusio/dependabot/npm_and_yarn/guides/ellipt...2e12786
Merge pull request #3933 from nebulab/spaghetticode/migrate-to-address-namec6b3697
Bump elliptic from 6.5.3 to 6.5.4 in /guides87203d5
Addmigrate_address_names
task to 2.11 upgrade taskb7ba9ad
Add Address name data migration rake task26d6596
Merge pull request #3969 from nebulab/kennyadsl/add-activestorage-dummy-exten...db7ff8d
Configure Active Storage on dummy apps for extensionsDependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) - `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language - `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language - `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language - `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language - `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com): - Update frequency (including time of day and day of week) - Pull request limits (per update run and/or open at any time) - Out-of-range updates (receive only lockfile updates, if desired) - Security updates (receive only security updates, if desired)