This release improves the overall performance of Spree applications and brings many bug fixes we backported from Vendo. Major highlights are:
💻 new API endpoints for handling Wishlists and Variants in Storefront API
👨💻 improved Webhooks
💸 improved Store Credits
🐛 Sentry error reporting integration for API
Alongside this release, we've also launched a completely new Spree website and highlighted massive new features coming in Spree 5 🚀
How to upgrade
Please follow Spree 4.9 upgrade guide
Spree Core
- Fix destroying carts with addresses assigned to other complete orders by @mad-eel in #12055
- Nicer name for default stock location by @damianlegawiec in #12056
- Added handy methods to the Wishlist model by @damianlegawiec in #12057
- Added a bunch of handy methods by @damianlegawiec in #12058
- Shipping Rate fixes by @damianlegawiec in #12059
- Improve
TaxRate#label
to display it right by @damianlegawiec in #12060 - Added
StockLocation#address
method and ability to add encryption by @damianlegawiec in #12061 - added soft delete to
StockLocation
by @damianlegawiec in #12062 - Added a bunch of helper utility methods by @damianlegawiec in #12063
- Extended Shipment model with helper methods by @damianlegawiec in #12064
- Add
apply_only_on_full_priced_items
preference toFlatRate
, `Flex… by @damianlegawiec in #12068 - Replace decorator usage in
spree_emails
with plain ruby modules by @damianlegawiec in #12069 - Added universal webhook interfaces to avoid using decorators by @damianlegawiec in #12070
- added missing ShippingMethod and ShippingCategory serializers for Sto… by @damianlegawiec in #12072
- Fixed: do not allow to create line items when there's no price in the… by @damianlegawiec in #12073
- Make Store Credits more flexible by @damianlegawiec in #12074
- Ability to configure/override
Spree::Address
validation to make it … by @damianlegawiec in #12076 - Add some scopes to payments and store credits by @mad-eel in #12077
- Fix coupon codes with some chars can't be removed from cart by @zavan in #12075
- Fixed:
LineItem#product
to also return soft-deleted products by @damianlegawiec in #12078 - Fixed:
Store#current
- removed deprecation, use dependencies by @damianlegawiec in #12080 - Set doorkeeper tokens expiration date to 1 month by @damianlegawiec in #12081
- Update
Spree::OrderMerger
and addSpree::Seeds::PaymentMethods
by @mad-eel in #12082 - Use
RequestStore
to store whether webhooks are disabled by @Vegann in #12083 - Allow Spree classes to specify which relationships should be included in webhook by @Vegann in #12084
- Fixed:
Spree::Money
correctly parses and displays Danish Krone by @damianlegawiec in #12085 - Use
Spree::Taxon.for_store
scope when resolving taxons in Products finder by @mbajur in #12087 - Fix Store Credit and Refund serializers by @mad-eel in #12088
- Performance: use loaded associations in
Quantifier
to speeds things up by @damianlegawiec in #12092 - Added
ShippingMethod
display_on
based scopes by @damianlegawiec in #12093 - Improve performance of Zone/Countries seeds by @damianlegawiec in #12094
- Use
admin_user_class
forRoleUser
association by @damianlegawiec in #12095 - Expire variants cache when changing position of master variant images by @damianlegawiec in #12096
- fix free shipping promotion by @damianlegawiec in #12097
- Ability to pass
email
toFirstOrder
promotion rule by @damianlegawiec in #12098 - Add weight and item total preferences to the
Spree::Calculator::Shipping::FlatRate
calculator by @mad-eel in #12099 - Added
order_includes
toControllerHelpers::Order
by @damianlegawiec in #12100 - Improve performance of
LineItems::FindByVariant
finder by @damianlegawiec in #12101 - Fixed: raise an error when trying to add a variant without price in s… by @damianlegawiec in #12103
- Fix
Spree::ShippingMethod.available
scope by @mad-eel in #12102 - Auto-Remove items from cart when not available in new currency by @damianlegawiec in #12104
- Improve & simpluft collection caching in API by @damianlegawiec in #12106
- Improve error rendering in
OrderConcern#render_order
when request f… by @damianlegawiec in #12107 - Move ActiveStorage code into
Spree::Asset
by @damianlegawiec in #12115 - Use
admin_user_class
inAuthorizationHelpers
by @damianlegawiec in #12116 - Improve flexibility and extensibility of webhooks matchers by @damianlegawiec in #12118
Spree API
- Added 2 new Wishlists API endpoints:
add_items
andremove_items
f… by @damianlegawiec in #12105 - Added Storefront Variants API endpoint by @damianlegawiec in #12065
- Fixed API error reporting to actually use the Error reporter for all … by @damianlegawiec in #12067
- Fixed: Storefront Products API now works with old slugs as well by @damianlegawiec in #12066
- Use Runtime configuration for API config by @damianlegawiec in #12071
- Fixed: Webhooks: don't log as error messages a success by @damianlegawiec in #12091
- Added
WebhookSubscriber#latest_event_at
by @damianlegawiec in #12090 - Fixed setting SSL for webhooks based on the URL and not the environment by @damianlegawiec in #12089
- Fixed
rake test_app
for API gem by @damianlegawiec in #12117 - Automatically detect Sentry and report API errors by @damianlegawiec in #12108
Full Changelog: v4.8.3...v4.9.0