diff --git a/.github/dependabot.yml b/.github/dependabot.yml
index 0ee37b8f..89829c70 100644
--- a/.github/dependabot.yml
+++ b/.github/dependabot.yml
@@ -12,3 +12,7 @@ updates:
- dependency-name: actionpack
versions:
- 6.1.2.1
+- package-ecosystem: github-actions
+ directory: "/"
+ schedule:
+ interval: monthly
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index a8cafe9e..f2134fb2 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -14,7 +14,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
- ruby: ['3.1', '3.2', '3.3']
+ ruby: ['3.2', '3.3']
gemfile:
- rails_6_1
- rails_7
@@ -29,7 +29,7 @@ jobs:
steps:
- name: SQLite3 version
run: sqlite3 --version
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
@@ -51,7 +51,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
- ruby: ['3.1', '3.2', '3.3']
+ ruby: ['3.2', '3.3']
gemfile:
- rails_6_1
- rails_7
@@ -72,7 +72,7 @@ jobs:
ports: ['5432:5432']
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
@@ -94,7 +94,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
- ruby: ['3.1', '3.2', '3.3']
+ ruby: ['3.2', '3.3']
gemfile:
- rails_6_1
- rails_7
@@ -115,7 +115,7 @@ jobs:
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
steps:
- - uses: actions/checkout@v3
+ - uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 22a10468..3748d15f 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,11 @@
### Unreleased
+### 8.1.0
+
+* Stripe v13
+* Remove OpenStruct dependency
+
### 8.0.0
* [Breaking] Remove `pay_customer.payment_method_token` virtual attribute. Use `@pay_customer.update_payment_method(token)` instead.
diff --git a/Gemfile b/Gemfile
index afc89d40..8b9d46c1 100644
--- a/Gemfile
+++ b/Gemfile
@@ -19,8 +19,8 @@ gem "webmock"
gem "braintree", ">= 2.92.0"
gem "lemonsqueezy", "~> 1.0"
-gem "paddle", "~> 2.4"
-gem "stripe", "~> 12.0"
+gem "paddle", "~> 2.6"
+gem "stripe", "~> 13.0"
gem "prawn"
gem "receipts"
diff --git a/Gemfile.lock b/Gemfile.lock
index 31ad4a46..d3f38345 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -1,6 +1,6 @@
GIT
remote: https://github.com/thoughtbot/appraisal.git
- revision: c83f8376d8f1024d999433010cf81948d56b937e
+ revision: 24feeea4c5c1d2e7a5f95d053da61858c6bfb2b1
specs:
appraisal (2.5.0)
bundler
@@ -10,7 +10,7 @@ GIT
PATH
remote: .
specs:
- pay (8.0.0)
+ pay (8.1.0)
rails (>= 6.0.0)
GEM
@@ -92,7 +92,7 @@ GEM
base64 (0.2.0)
bigdecimal (3.1.8)
bindex (0.8.1)
- braintree (4.21.0)
+ braintree (4.22.0)
builder (>= 3.2.4)
rexml (>= 3.1.9)
builder (3.3.0)
@@ -113,14 +113,14 @@ GEM
globalid (1.2.1)
activesupport (>= 6.1)
hashdiff (1.1.1)
- i18n (1.14.5)
+ i18n (1.14.6)
concurrent-ruby (~> 1.0)
importmap-rails (2.0.1)
actionpack (>= 6.0.0)
activesupport (>= 6.0.0)
railties (>= 6.0.0)
io-console (0.7.2)
- irb (1.14.0)
+ irb (1.14.1)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
json (2.7.2)
@@ -147,7 +147,7 @@ GEM
mysql2 (0.5.6)
net-http (0.4.1)
uri
- net-imap (0.4.15)
+ net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
@@ -164,14 +164,16 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
- paddle (2.5.1)
- faraday (~> 2.0)
+ ostruct (0.6.0)
+ paddle (2.6.0)
+ faraday (~> 2.11.0)
+ ostruct (~> 0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
pdf-core (0.10.0)
- pg (1.5.7)
+ pg (1.5.8)
prawn (2.5.0)
matrix (~> 0.4)
pdf-core (~> 0.10.0)
@@ -181,7 +183,7 @@ GEM
psych (5.1.2)
stringio
public_suffix (6.0.1)
- puma (6.4.2)
+ puma (6.4.3)
nio4r (~> 2.0)
racc (1.8.1)
rack (3.1.7)
@@ -229,9 +231,9 @@ GEM
prawn (>= 1.3.0, < 3.0.0)
prawn-table (~> 0.2.1)
regexp_parser (2.9.2)
- reline (0.5.9)
+ reline (0.5.10)
io-console (~> 0.5)
- rexml (3.3.7)
+ rexml (3.3.8)
rubocop (1.65.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
@@ -243,7 +245,7 @@ GEM
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
- rubocop-ast (1.32.2)
+ rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.21.1)
rubocop (>= 1.48.1, < 2.0)
@@ -258,10 +260,10 @@ GEM
actionpack (>= 6.1)
activesupport (>= 6.1)
sprockets (>= 3.0.0)
- sqlite3 (2.0.4)
+ sqlite3 (2.1.0)
mini_portile2 (~> 2.8.0)
- sqlite3 (2.0.4-x86_64-darwin)
- sqlite3 (2.0.4-x86_64-linux-gnu)
+ sqlite3 (2.1.0-x86_64-darwin)
+ sqlite3 (2.1.0-x86_64-linux-gnu)
standard (1.40.0)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.0)
@@ -277,18 +279,17 @@ GEM
stimulus-rails (1.3.4)
railties (>= 6.0.0)
stringio (3.1.1)
- stripe (12.5.0)
+ stripe (13.0.0)
thor (1.3.2)
timeout (0.4.1)
ttfunk (1.8.0)
bigdecimal (~> 3.1)
- turbo-rails (2.0.6)
+ turbo-rails (2.0.10)
actionpack (>= 6.0.0)
- activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
- unicode-display_width (2.5.0)
+ unicode-display_width (2.6.0)
uri (0.13.1)
useragent (0.16.10)
vcr (6.3.1)
@@ -298,11 +299,11 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- webmock (3.23.1)
+ webmock (3.24.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
- webrick (1.8.1)
+ webrick (1.8.2)
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
@@ -323,7 +324,7 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
- paddle (~> 2.4)
+ paddle (~> 2.6)
pay!
pg
prawn
@@ -333,7 +334,7 @@ DEPENDENCIES
sqlite3
standard
stimulus-rails
- stripe (~> 12.0)
+ stripe (~> 13.0)
turbo-rails
vcr
web-console
diff --git a/UPGRADE.md b/UPGRADE.md
index ba6d0da1..cee3c8e2 100644
--- a/UPGRADE.md
+++ b/UPGRADE.md
@@ -1,17 +1,19 @@
-# **Upgrade Guide**
+# Upgrade Guide
Follow this guide to upgrade older Pay versions. These may require database migrations and code changes.
-### ** Pay 7.0 to Pay 8.0**
+## Pay 7.0 to Pay 8.0
+
+Pay has moved to using Single Table Inheritance to handle each payment processor's functionality. To do this, we've provided a migration to update the existing records.
```bash
rails pay:install:migrations
rails db:migrate
```
-The `PaymentMethod#type` column has been renamed to `payment_method_type`. If you're displaying payment method details, you'll need to update your views to use the new column name.
+The `PaymentMethod#type` column has been renamed to `payment_method_type` to prevent conflicting with STI. If you're displaying payment method details, you'll need to update your views to use the new column name.
-## **Pay 6.0 to Pay 7.0**
+## Pay 6.0 to Pay 7.0
Pay 7 introduces some changes for Stripe and requires a few additional columns.
@@ -52,7 +54,7 @@ The secrets/environment variables for Paddle have also been renamed to from `PAD
The `paddle_pay` gem requirement has been replaced with `paddle`, which contains APIs for both Paddle Billing and Classic.
-## **Pay 5.0 to 6.0**
+## Pay 5.0 to 6.0
This version adds support for accessing the start and end of the current billing period of a subscription. This currently only works with Stripe subscriptions.
Fields changed:
@@ -93,11 +95,11 @@ end
Stripe subscriptions created before this upgrade will gain the `current_period_start` and `current_period_end` attributes the next time they are synced. You can manually sync a Stripe subscription by running `Pay::Stripe::Subscription.sync("STRIPE_SUBSCRIPTION_ID")`
-## **Pay 3.0 to 4.0**
+## Pay 3.0 to 4.0
This is a major change to add Stripe tax support, Stripe metered billing, new configuration options for payment processors and emails, syncing additional customer attributes to Stripe and Braintree, and improving the architecture of Pay.
-### **Jump to a topic**
+### Jump to a topic
- [Method Additions and Changes](#method-additions-and-changes)
- [Custom Email Sending Configuration](#custom-email-sending-configuration)
- [Customer Attributes](#customer-attributes)
@@ -106,7 +108,7 @@ This is a major change to add Stripe tax support, Stripe metered billing, new co
- [Enabling Payment Processors](#enabling-payment-processors)
- [Supported Dependency Notifications](#supported-dependency-notifications)
-### **Method Additions and Changes**
+### Method Additions and Changes
In an effort to keep a consistant naming convention, the email parameters of `subscription` and `charge` have been updated to have `pay_` prepended to them (`pay_subscription` and `pay_charge` respectively). If you are directly using any of the built in emails or created custom Pay views, you will want to be sure to update your parameter names to the updated names.
@@ -126,7 +128,7 @@ The `set_payment_processor` method has a `make_default` optional argument that d
Setting the `metadata["pay_name"]` option on a `Stripe::Subscription` object will now set the subscription name if present. Otherwise the `Pay.default_product_name` will be used to set the name.
-### **Custom Email Sending Configuration**
+### Custom Email Sending Configuration
Previously, Pay would send out the following emails based on the value of the `send_emails` configuration variable, which was set to true by default:
@@ -150,7 +152,7 @@ end
```
The above example shows the exact defaults that come pre-configured from Pay. The `config.emails.subscription_renewing` example is specific to Stripe but illustrates how a lambda can be used as a way to evaluate more complex conditions to determine whether an email should be sent. All of these settings can be overridden using the initializer mentioned previously and setting your own values for each email.
-### **Customer Attributes**
+### Customer Attributes
The `pay_customer` macro now accepts options for `stripe_attributes` and `braintree_attributes`. These options can accept a method name or a lambda that returns a hash of `pay_customer` attributes. For example:
```ruby
@@ -176,7 +178,7 @@ end
Being able to send additional customer attributes to Stripe such as the customers address gives you the ability to leverage Stripe's tax support!
-### **Stripe Tax Support**
+### Stripe Tax Support
Using `pay_customer stripe_attributes: :method_name`, you can add an `address` key to `Stripe::Customer` objects which will be used for calculating taxes. `total_tax_amounts` are recorded to `Pay::Charge` records. This includes details for each tax applied to the charge, for example if there are multiple jurisdictions involved. Additionally, when subscribing a customer to a plan the `automatic_tax:` parameter can be enabled as shown here:
@@ -184,7 +186,7 @@ Using `pay_customer stripe_attributes: :method_name`, you can add an `address` k
@user.payment_processor.subscribe(plan: "growth", automatic_tax: { enabled: true })
```
-### **Stripe Metered Billing Support**
+### Stripe Metered Billing Support
Stripe metered billing support removes `quantity` when creating a new subscription (metered billing prices do not allow quantity). Adds `create_usage_record` to `Pay::Subscription` for reporting usage on metered billing plans. The `create_usage_record` method takes a hash of options, see the example below:
```ruby
@@ -192,7 +194,7 @@ create_usage_record(subscription_item_id: "si_1234", quantity: 100, action: :set
```
To learn more about creating usage records, see [reporting usage](https://stripe.com/docs/products-prices/pricing-models#reporting-usage)
-### **Enabling Payment Processors**
+### Enabling Payment Processors
Previously, all payment processors were enabled by default. With this new release, Pay now allows you to enable any of the payment processors independently. The use case here is that perhaps you already have an implementation in place in your application for one of the processors that we allow integration with and do not want the Pay implementation to conflict. In such a case you can create or add to an initializer at `config/initializers/pay.rb` the following line, including in the array only the process that you wish Pay to setup in your application:
```ruby
@@ -204,7 +206,7 @@ Pay.setup do |config|
end
```
-### **Supported Dependency Notifications**
+### Supported Dependency Notifications
As Pay is working to setup the payment processors that you have enabled it performs a version check on each to ensure that you are using a compatible version.
@@ -218,11 +220,11 @@ If you are using a non-compatible version Pay will raise an error message to not
---
-## **Pay 2.x to Pay 3.0**
+## Pay 2.x to Pay 3.0
This is a major change to add support for multiple payment methods, fixing bugs, and improving the architecture of Pay.
-### **Jump to a topic**
+### Jump to a topic
- [Database Migrations](#database-migrations)
- [Pay::Customer](#paycustomer)
- [Payment Processor](#payment-processor)
@@ -231,7 +233,7 @@ This is a major change to add support for multiple payment methods, fixing bugs,
- [Payment Methods](#payment-methods)
- [Configuration Changes](#configuration-changes)
-### **Database Migrations**
+### Database Migrations
Upgrading from Pay 2.x to 3.0 requires moving data for several things:
@@ -438,7 +440,7 @@ After running migrations, run the following to sync the customer default payment
rake pay:payment_methods:sync_default
```
-### **Pay::Customer**
+### Pay::Customer
The `Pay::Billable` module has been removed and is replaced with `pay_customer` method on your models.
@@ -465,7 +467,7 @@ user.pay_customers
#=> Returns all the pay customers associated with this User
```
-### **Payment Processor**
+### Payment Processor
Instead of calling `@user.charge`, Pay 3 moves the `charge`, `subscribe`, and other methods to the `payment_processor` association. This significantly reduces the methods added to the User model.
@@ -486,7 +488,7 @@ user.payment_processor.subscribe(plan: "whatever")
# Creates Pay::Subscription record for the subscription
```
-### **Generic Trials**
+### Generic Trials
Generic trials are now done using the fake payment processor
@@ -496,11 +498,11 @@ user.payment_processor.subscribe(trial_ends_at: 14.days.from_now, ends_at: 14.da
user.payment_processor.on_trial? #=> true
```
-### **Charges & Subscriptions**
+### Charges & Subscriptions
`Pay::Charge` and `Pay::Subscription` are associated `Pay::Customer` and no longer directly connected to the `owner`
-### **Payment Methods**
+### Payment Methods
Pay 3 now keeps track of multiple payment methods. Each is associated with a Pay::Customer and one is marked as the default.
@@ -517,7 +519,7 @@ charge.payment_method_type #=> "paypal"
charge.email #=> "test@example.org"
```
-### **Configuration Changes**
+### Configuration Changes
We've removed several configuration options since Pay 3+ will always use the models from the gem for charges, subscriptions, etc.
diff --git a/app/models/pay/braintree/subscription.rb b/app/models/pay/braintree/subscription.rb
index c08841cd..df3d4129 100644
--- a/app/models/pay/braintree/subscription.rb
+++ b/app/models/pay/braintree/subscription.rb
@@ -191,7 +191,7 @@ def switching_to_monthly_plan?(current_plan, plan)
def discount_for_switching_to_monthly(current_plan, plan)
cycles = (money_remaining_on_yearly_plan(current_plan) / plan.price).floor
- OpenStruct.new(
+ ActiveSupport::InheritableOptions.new(
amount: plan.price,
number_of_billing_cycles: cycles
)
@@ -209,7 +209,7 @@ def discount_for_switching_to_yearly(amount: 0)
end
end
- OpenStruct.new(amount: amount, number_of_billing_cycles: 1)
+ ActiveSupport::InheritableOptions.new(amount: amount, number_of_billing_cycles: 1)
end
def swap_across_frequencies(plan)
diff --git a/app/models/pay/webhook.rb b/app/models/pay/webhook.rb
index f1a32669..fc4023ff 100644
--- a/app/models/pay/webhook.rb
+++ b/app/models/pay/webhook.rb
@@ -32,7 +32,7 @@ def rehydrated_event
def to_recursive_ostruct(obj)
if obj.is_a?(Hash)
- OpenStruct.new(obj.map { |key, val| [key, to_recursive_ostruct(val)] }.to_h)
+ ActiveSupport::InheritableOptions.new(obj.map { |key, val| [key.to_sym, to_recursive_ostruct(val)] }.to_h)
elsif obj.is_a?(Array)
obj.map { |o| to_recursive_ostruct(o) }
else # Assumed to be a primitive value
diff --git a/docs/paddle_billing/2_javascript.md b/docs/paddle_billing/2_javascript.md
index 373de7ad..3310ed8e 100644
--- a/docs/paddle_billing/2_javascript.md
+++ b/docs/paddle_billing/2_javascript.md
@@ -11,8 +11,8 @@ Add the Paddle.js script in your application layout and initialize it with your
```
diff --git a/docs/stripe/5_webhooks.md b/docs/stripe/5_webhooks.md
index 8fdfb9ce..789f2dd5 100644
--- a/docs/stripe/5_webhooks.md
+++ b/docs/stripe/5_webhooks.md
@@ -54,6 +54,8 @@ checkout.session.completed
checkout.session.async_payment_succeeded
```
+[Click here](https://dashboard.stripe.com/webhooks/create?events=charge.succeeded%2Ccharge.refunded%2Cpayment_intent.succeeded%2Cinvoice.upcoming%2Cinvoice.payment_action_required%2Ccustomer.subscription.created%2Ccustomer.subscription.updated%2Ccustomer.subscription.deleted%2Ccustomer.subscription.trial_will_end%2Ccustomer.updated%2Ccustomer.deleted%2Cpayment_method.attached%2Cpayment_method.updated%2Cpayment_method.automatically_updated%2Cpayment_method.detached%2Caccount.updated%2Ccheckout.session.completed%2Ccheckout.session.async_payment_succeeded) to create a new Stripe webhook with all the events pre-filled.
+
## Next
See [Metered Billing](6_metered_billing.md)
diff --git a/gemfiles/rails_6_1.gemfile b/gemfiles/rails_6_1.gemfile
index 7a9a8851..d7e93715 100644
--- a/gemfiles/rails_6_1.gemfile
+++ b/gemfiles/rails_6_1.gemfile
@@ -9,8 +9,8 @@ gem "vcr"
gem "webmock"
gem "braintree", ">= 2.92.0"
gem "lemonsqueezy", "~> 1.0"
-gem "paddle", "~> 2.4"
-gem "stripe", "~> 12.0"
+gem "paddle", "~> 2.6"
+gem "stripe", "~> 13.0"
gem "prawn"
gem "receipts"
gem "mysql2"
diff --git a/gemfiles/rails_6_1.gemfile.lock b/gemfiles/rails_6_1.gemfile.lock
index c1acdf6f..7487ecb4 100644
--- a/gemfiles/rails_6_1.gemfile.lock
+++ b/gemfiles/rails_6_1.gemfile.lock
@@ -1,6 +1,6 @@
GIT
remote: https://github.com/thoughtbot/appraisal.git
- revision: c83f8376d8f1024d999433010cf81948d56b937e
+ revision: 24feeea4c5c1d2e7a5f95d053da61858c6bfb2b1
specs:
appraisal (2.5.0)
bundler
@@ -10,7 +10,7 @@ GIT
PATH
remote: ..
specs:
- pay (8.0.0)
+ pay (8.1.0)
rails (>= 6.0.0)
GEM
@@ -81,7 +81,7 @@ GEM
base64 (0.2.0)
bigdecimal (3.1.8)
bindex (0.8.1)
- braintree (4.21.0)
+ braintree (4.22.0)
builder (>= 3.2.4)
rexml (>= 3.1.9)
builder (3.3.0)
@@ -100,7 +100,7 @@ GEM
globalid (1.2.1)
activesupport (>= 6.1)
hashdiff (1.1.1)
- i18n (1.14.5)
+ i18n (1.14.6)
concurrent-ruby (~> 1.0)
importmap-rails (2.0.1)
actionpack (>= 6.0.0)
@@ -130,7 +130,7 @@ GEM
mysql2 (0.5.6)
net-http (0.4.1)
uri
- net-imap (0.4.15)
+ net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
@@ -146,14 +146,16 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
- paddle (2.5.1)
- faraday (~> 2.0)
+ ostruct (0.6.0)
+ paddle (2.6.0)
+ faraday (~> 2.11.0)
+ ostruct (~> 0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
pdf-core (0.10.0)
- pg (1.5.7)
+ pg (1.5.8)
prawn (2.5.0)
matrix (~> 0.4)
pdf-core (~> 0.10.0)
@@ -161,7 +163,7 @@ GEM
prawn-table (0.2.2)
prawn (>= 1.3.0, < 3.0.0)
public_suffix (6.0.1)
- puma (6.4.2)
+ puma (6.4.3)
nio4r (~> 2.0)
racc (1.8.1)
rack (2.2.9)
@@ -201,7 +203,7 @@ GEM
prawn (>= 1.3.0, < 3.0.0)
prawn-table (~> 0.2.1)
regexp_parser (2.9.2)
- rexml (3.3.7)
+ rexml (3.3.8)
rubocop (1.65.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
@@ -213,7 +215,7 @@ GEM
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
- rubocop-ast (1.32.2)
+ rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.21.1)
rubocop (>= 1.48.1, < 2.0)
@@ -244,18 +246,17 @@ GEM
rubocop-performance (~> 1.21.0)
stimulus-rails (1.3.4)
railties (>= 6.0.0)
- stripe (12.5.0)
+ stripe (13.0.0)
thor (1.3.2)
timeout (0.4.1)
ttfunk (1.8.0)
bigdecimal (~> 3.1)
- turbo-rails (2.0.6)
+ turbo-rails (2.0.10)
actionpack (>= 6.0.0)
- activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
- unicode-display_width (2.5.0)
+ unicode-display_width (2.6.0)
uri (0.13.1)
vcr (6.3.1)
base64
@@ -264,7 +265,7 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- webmock (3.23.1)
+ webmock (3.24.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
@@ -293,7 +294,7 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
- paddle (~> 2.4)
+ paddle (~> 2.6)
pay!
pg
prawn
@@ -304,7 +305,7 @@ DEPENDENCIES
sqlite3 (~> 1.4)
standard
stimulus-rails
- stripe (~> 12.0)
+ stripe (~> 13.0)
turbo-rails
vcr
web-console
diff --git a/gemfiles/rails_7.gemfile b/gemfiles/rails_7.gemfile
index d96eb3e8..1b5e20fb 100644
--- a/gemfiles/rails_7.gemfile
+++ b/gemfiles/rails_7.gemfile
@@ -9,8 +9,8 @@ gem "vcr"
gem "webmock"
gem "braintree", ">= 2.92.0"
gem "lemonsqueezy", "~> 1.0"
-gem "paddle", "~> 2.4"
-gem "stripe", "~> 12.0"
+gem "paddle", "~> 2.6"
+gem "stripe", "~> 13.0"
gem "prawn"
gem "receipts"
gem "mysql2"
diff --git a/gemfiles/rails_7.gemfile.lock b/gemfiles/rails_7.gemfile.lock
index b913b9fc..684371b4 100644
--- a/gemfiles/rails_7.gemfile.lock
+++ b/gemfiles/rails_7.gemfile.lock
@@ -1,6 +1,6 @@
GIT
remote: https://github.com/thoughtbot/appraisal.git
- revision: c83f8376d8f1024d999433010cf81948d56b937e
+ revision: 24feeea4c5c1d2e7a5f95d053da61858c6bfb2b1
specs:
appraisal (2.5.0)
bundler
@@ -10,7 +10,7 @@ GIT
PATH
remote: ..
specs:
- pay (8.0.0)
+ pay (8.1.0)
rails (>= 6.0.0)
GEM
@@ -87,7 +87,7 @@ GEM
base64 (0.2.0)
bigdecimal (3.1.8)
bindex (0.8.1)
- braintree (4.21.0)
+ braintree (4.22.0)
builder (>= 3.2.4)
rexml (>= 3.1.9)
builder (3.3.0)
@@ -106,7 +106,7 @@ GEM
globalid (1.2.1)
activesupport (>= 6.1)
hashdiff (1.1.1)
- i18n (1.14.5)
+ i18n (1.14.6)
concurrent-ruby (~> 1.0)
importmap-rails (2.0.1)
actionpack (>= 6.0.0)
@@ -136,7 +136,7 @@ GEM
mysql2 (0.5.6)
net-http (0.4.1)
uri
- net-imap (0.4.15)
+ net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
@@ -152,14 +152,16 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
- paddle (2.5.1)
- faraday (~> 2.0)
+ ostruct (0.6.0)
+ paddle (2.6.0)
+ faraday (~> 2.11.0)
+ ostruct (~> 0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
pdf-core (0.10.0)
- pg (1.5.7)
+ pg (1.5.8)
prawn (2.5.0)
matrix (~> 0.4)
pdf-core (~> 0.10.0)
@@ -167,7 +169,7 @@ GEM
prawn-table (0.2.2)
prawn (>= 1.3.0, < 3.0.0)
public_suffix (6.0.1)
- puma (6.4.2)
+ puma (6.4.3)
nio4r (~> 2.0)
racc (1.8.1)
rack (2.2.9)
@@ -207,7 +209,7 @@ GEM
prawn (>= 1.3.0, < 3.0.0)
prawn-table (~> 0.2.1)
regexp_parser (2.9.2)
- rexml (3.3.7)
+ rexml (3.3.8)
rubocop (1.65.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
@@ -219,7 +221,7 @@ GEM
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
- rubocop-ast (1.32.2)
+ rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.21.1)
rubocop (>= 1.48.1, < 2.0)
@@ -250,18 +252,17 @@ GEM
rubocop-performance (~> 1.21.0)
stimulus-rails (1.3.4)
railties (>= 6.0.0)
- stripe (12.5.0)
+ stripe (13.0.0)
thor (1.3.2)
timeout (0.4.1)
ttfunk (1.8.0)
bigdecimal (~> 3.1)
- turbo-rails (2.0.6)
+ turbo-rails (2.0.10)
actionpack (>= 6.0.0)
- activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
- unicode-display_width (2.5.0)
+ unicode-display_width (2.6.0)
uri (0.13.1)
vcr (6.3.1)
base64
@@ -270,7 +271,7 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- webmock (3.23.1)
+ webmock (3.24.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
@@ -299,7 +300,7 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
- paddle (~> 2.4)
+ paddle (~> 2.6)
pay!
pg
prawn
@@ -310,7 +311,7 @@ DEPENDENCIES
sqlite3 (~> 1.4)
standard
stimulus-rails
- stripe (~> 12.0)
+ stripe (~> 13.0)
turbo-rails
vcr
web-console
diff --git a/gemfiles/rails_7_1.gemfile b/gemfiles/rails_7_1.gemfile
index 4ffc2ff4..75335575 100644
--- a/gemfiles/rails_7_1.gemfile
+++ b/gemfiles/rails_7_1.gemfile
@@ -9,8 +9,8 @@ gem "vcr"
gem "webmock"
gem "braintree", ">= 2.92.0"
gem "lemonsqueezy", "~> 1.0"
-gem "paddle", "~> 2.4"
-gem "stripe", "~> 12.0"
+gem "paddle", "~> 2.6"
+gem "stripe", "~> 13.0"
gem "prawn"
gem "receipts"
gem "mysql2"
diff --git a/gemfiles/rails_7_1.gemfile.lock b/gemfiles/rails_7_1.gemfile.lock
index 31db494a..9f4bcee2 100644
--- a/gemfiles/rails_7_1.gemfile.lock
+++ b/gemfiles/rails_7_1.gemfile.lock
@@ -1,6 +1,6 @@
GIT
remote: https://github.com/thoughtbot/appraisal.git
- revision: c83f8376d8f1024d999433010cf81948d56b937e
+ revision: 24feeea4c5c1d2e7a5f95d053da61858c6bfb2b1
specs:
appraisal (2.5.0)
bundler
@@ -10,7 +10,7 @@ GIT
PATH
remote: ..
specs:
- pay (8.0.0)
+ pay (8.1.0)
rails (>= 6.0.0)
GEM
@@ -96,7 +96,7 @@ GEM
base64 (0.2.0)
bigdecimal (3.1.8)
bindex (0.8.1)
- braintree (4.21.0)
+ braintree (4.22.0)
builder (>= 3.2.4)
rexml (>= 3.1.9)
builder (3.3.0)
@@ -117,14 +117,14 @@ GEM
globalid (1.2.1)
activesupport (>= 6.1)
hashdiff (1.1.1)
- i18n (1.14.5)
+ i18n (1.14.6)
concurrent-ruby (~> 1.0)
importmap-rails (2.0.1)
actionpack (>= 6.0.0)
activesupport (>= 6.0.0)
railties (>= 6.0.0)
io-console (0.7.2)
- irb (1.14.0)
+ irb (1.14.1)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
json (2.7.2)
@@ -151,7 +151,7 @@ GEM
mysql2 (0.5.6)
net-http (0.4.1)
uri
- net-imap (0.4.15)
+ net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
@@ -167,14 +167,16 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
- paddle (2.5.1)
- faraday (~> 2.0)
+ ostruct (0.6.0)
+ paddle (2.6.0)
+ faraday (~> 2.11.0)
+ ostruct (~> 0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
pdf-core (0.10.0)
- pg (1.5.7)
+ pg (1.5.8)
prawn (2.5.0)
matrix (~> 0.4)
pdf-core (~> 0.10.0)
@@ -184,7 +186,7 @@ GEM
psych (5.1.2)
stringio
public_suffix (6.0.1)
- puma (6.4.2)
+ puma (6.4.3)
nio4r (~> 2.0)
racc (1.8.1)
rack (3.1.7)
@@ -232,9 +234,9 @@ GEM
prawn (>= 1.3.0, < 3.0.0)
prawn-table (~> 0.2.1)
regexp_parser (2.9.2)
- reline (0.5.9)
+ reline (0.5.10)
io-console (~> 0.5)
- rexml (3.3.7)
+ rexml (3.3.8)
rubocop (1.65.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
@@ -246,7 +248,7 @@ GEM
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
- rubocop-ast (1.32.2)
+ rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.21.1)
rubocop (>= 1.48.1, < 2.0)
@@ -278,18 +280,17 @@ GEM
stimulus-rails (1.3.4)
railties (>= 6.0.0)
stringio (3.1.1)
- stripe (12.5.0)
+ stripe (13.0.0)
thor (1.3.2)
timeout (0.4.1)
ttfunk (1.8.0)
bigdecimal (~> 3.1)
- turbo-rails (2.0.6)
+ turbo-rails (2.0.10)
actionpack (>= 6.0.0)
- activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
- unicode-display_width (2.5.0)
+ unicode-display_width (2.6.0)
uri (0.13.1)
vcr (6.3.1)
base64
@@ -298,11 +299,11 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- webmock (3.23.1)
+ webmock (3.24.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
- webrick (1.8.1)
+ webrick (1.8.2)
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
@@ -325,7 +326,7 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
- paddle (~> 2.4)
+ paddle (~> 2.6)
pay!
pg
prawn
@@ -336,7 +337,7 @@ DEPENDENCIES
sqlite3 (~> 1.4)
standard
stimulus-rails
- stripe (~> 12.0)
+ stripe (~> 13.0)
turbo-rails
vcr
web-console
diff --git a/gemfiles/rails_7_2.gemfile b/gemfiles/rails_7_2.gemfile
index 851a39d8..3a9e5396 100644
--- a/gemfiles/rails_7_2.gemfile
+++ b/gemfiles/rails_7_2.gemfile
@@ -9,8 +9,8 @@ gem "vcr"
gem "webmock"
gem "braintree", ">= 2.92.0"
gem "lemonsqueezy", "~> 1.0"
-gem "paddle", "~> 2.4"
-gem "stripe", "~> 12.0"
+gem "paddle", "~> 2.6"
+gem "stripe", "~> 13.0"
gem "prawn"
gem "receipts"
gem "mysql2"
diff --git a/gemfiles/rails_7_2.gemfile.lock b/gemfiles/rails_7_2.gemfile.lock
index 8e6ee849..c0c91a0e 100644
--- a/gemfiles/rails_7_2.gemfile.lock
+++ b/gemfiles/rails_7_2.gemfile.lock
@@ -1,6 +1,6 @@
GIT
remote: https://github.com/thoughtbot/appraisal.git
- revision: c83f8376d8f1024d999433010cf81948d56b937e
+ revision: 24feeea4c5c1d2e7a5f95d053da61858c6bfb2b1
specs:
appraisal (2.5.0)
bundler
@@ -10,7 +10,7 @@ GIT
PATH
remote: ..
specs:
- pay (8.0.0)
+ pay (8.1.0)
rails (>= 6.0.0)
GEM
@@ -92,7 +92,7 @@ GEM
base64 (0.2.0)
bigdecimal (3.1.8)
bindex (0.8.1)
- braintree (4.21.0)
+ braintree (4.22.0)
builder (>= 3.2.4)
rexml (>= 3.1.9)
builder (3.3.0)
@@ -113,14 +113,14 @@ GEM
globalid (1.2.1)
activesupport (>= 6.1)
hashdiff (1.1.1)
- i18n (1.14.5)
+ i18n (1.14.6)
concurrent-ruby (~> 1.0)
importmap-rails (2.0.1)
actionpack (>= 6.0.0)
activesupport (>= 6.0.0)
railties (>= 6.0.0)
io-console (0.7.2)
- irb (1.14.0)
+ irb (1.14.1)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
json (2.7.2)
@@ -146,7 +146,7 @@ GEM
mysql2 (0.5.6)
net-http (0.4.1)
uri
- net-imap (0.4.15)
+ net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
@@ -162,14 +162,16 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
- paddle (2.5.1)
- faraday (~> 2.0)
+ ostruct (0.6.0)
+ paddle (2.6.0)
+ faraday (~> 2.11.0)
+ ostruct (~> 0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
pdf-core (0.10.0)
- pg (1.5.7)
+ pg (1.5.8)
prawn (2.5.0)
matrix (~> 0.4)
pdf-core (~> 0.10.0)
@@ -179,7 +181,7 @@ GEM
psych (5.1.2)
stringio
public_suffix (6.0.1)
- puma (6.4.2)
+ puma (6.4.3)
nio4r (~> 2.0)
racc (1.8.1)
rack (3.1.7)
@@ -227,9 +229,9 @@ GEM
prawn (>= 1.3.0, < 3.0.0)
prawn-table (~> 0.2.1)
regexp_parser (2.9.2)
- reline (0.5.9)
+ reline (0.5.10)
io-console (~> 0.5)
- rexml (3.3.7)
+ rexml (3.3.8)
rubocop (1.65.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
@@ -241,7 +243,7 @@ GEM
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
- rubocop-ast (1.32.2)
+ rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.21.1)
rubocop (>= 1.48.1, < 2.0)
@@ -256,9 +258,9 @@ GEM
actionpack (>= 6.1)
activesupport (>= 6.1)
sprockets (>= 3.0.0)
- sqlite3 (2.0.4-arm64-darwin)
- sqlite3 (2.0.4-x86_64-darwin)
- sqlite3 (2.0.4-x86_64-linux-gnu)
+ sqlite3 (2.1.0-arm64-darwin)
+ sqlite3 (2.1.0-x86_64-darwin)
+ sqlite3 (2.1.0-x86_64-linux-gnu)
standard (1.40.0)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.0)
@@ -274,18 +276,17 @@ GEM
stimulus-rails (1.3.4)
railties (>= 6.0.0)
stringio (3.1.1)
- stripe (12.5.0)
+ stripe (13.0.0)
thor (1.3.2)
timeout (0.4.1)
ttfunk (1.8.0)
bigdecimal (~> 3.1)
- turbo-rails (2.0.6)
+ turbo-rails (2.0.10)
actionpack (>= 6.0.0)
- activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
- unicode-display_width (2.5.0)
+ unicode-display_width (2.6.0)
uri (0.13.1)
useragent (0.16.10)
vcr (6.3.1)
@@ -295,11 +296,11 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- webmock (3.23.1)
+ webmock (3.24.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
- webrick (1.8.1)
+ webrick (1.8.2)
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
@@ -325,7 +326,7 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
- paddle (~> 2.4)
+ paddle (~> 2.6)
pay!
pg
prawn
@@ -336,7 +337,7 @@ DEPENDENCIES
sqlite3 (~> 2.0)
standard
stimulus-rails
- stripe (~> 12.0)
+ stripe (~> 13.0)
turbo-rails
vcr
web-console
diff --git a/gemfiles/rails_main.gemfile b/gemfiles/rails_main.gemfile
index 6eb0e1e9..30166755 100644
--- a/gemfiles/rails_main.gemfile
+++ b/gemfiles/rails_main.gemfile
@@ -9,8 +9,8 @@ gem "vcr"
gem "webmock"
gem "braintree", ">= 2.92.0"
gem "lemonsqueezy", "~> 1.0"
-gem "paddle", "~> 2.4"
-gem "stripe", "~> 12.0"
+gem "paddle", "~> 2.6"
+gem "stripe", "~> 13.0"
gem "prawn"
gem "receipts"
gem "mysql2"
diff --git a/gemfiles/rails_main.gemfile.lock b/gemfiles/rails_main.gemfile.lock
index c6f25158..e515d931 100644
--- a/gemfiles/rails_main.gemfile.lock
+++ b/gemfiles/rails_main.gemfile.lock
@@ -1,31 +1,31 @@
GIT
remote: https://github.com/rails/rails.git
- revision: 69c86f9606e490b24e8628dc47f34fbec6b321d1
+ revision: 9e49ab24edb8e79503329a44974bbb9d8e047917
branch: main
specs:
- actioncable (8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ actioncable (8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
zeitwerk (~> 2.6)
- actionmailbox (8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- activejob (= 8.0.0.alpha)
- activerecord (= 8.0.0.alpha)
- activestorage (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ actionmailbox (8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ activejob (= 8.0.0.beta1)
+ activerecord (= 8.0.0.beta1)
+ activestorage (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
mail (>= 2.8.0)
- actionmailer (8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- actionview (= 8.0.0.alpha)
- activejob (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ actionmailer (8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ actionview (= 8.0.0.beta1)
+ activejob (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
mail (>= 2.8.0)
rails-dom-testing (~> 2.2)
- actionpack (8.0.0.alpha)
- actionview (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ actionpack (8.0.0.beta1)
+ actionview (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
nokogiri (>= 1.8.5)
rack (>= 2.2.4)
rack-session (>= 1.0.1)
@@ -33,36 +33,37 @@ GIT
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
useragent (~> 0.16)
- actiontext (8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- activerecord (= 8.0.0.alpha)
- activestorage (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ actiontext (8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ activerecord (= 8.0.0.beta1)
+ activestorage (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
- actionview (8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ actionview (8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
builder (~> 3.1)
erubi (~> 1.11)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
- activejob (8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ activejob (8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
globalid (>= 0.3.6)
- activemodel (8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
- activerecord (8.0.0.alpha)
- activemodel (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ activemodel (8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
+ activerecord (8.0.0.beta1)
+ activemodel (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
timeout (>= 0.4.0)
- activestorage (8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- activejob (= 8.0.0.alpha)
- activerecord (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ activestorage (8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ activejob (= 8.0.0.beta1)
+ activerecord (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
marcel (~> 1.0)
- activesupport (8.0.0.alpha)
+ activesupport (8.0.0.beta1)
base64
+ benchmark (>= 0.3)
bigdecimal
concurrent-ruby (~> 1.0, >= 1.3.1)
connection_pool (>= 2.2.5)
@@ -73,23 +74,23 @@ GIT
securerandom (>= 0.3)
tzinfo (~> 2.0, >= 2.0.5)
uri (>= 0.13.1)
- rails (8.0.0.alpha)
- actioncable (= 8.0.0.alpha)
- actionmailbox (= 8.0.0.alpha)
- actionmailer (= 8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- actiontext (= 8.0.0.alpha)
- actionview (= 8.0.0.alpha)
- activejob (= 8.0.0.alpha)
- activemodel (= 8.0.0.alpha)
- activerecord (= 8.0.0.alpha)
- activestorage (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ rails (8.0.0.beta1)
+ actioncable (= 8.0.0.beta1)
+ actionmailbox (= 8.0.0.beta1)
+ actionmailer (= 8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ actiontext (= 8.0.0.beta1)
+ actionview (= 8.0.0.beta1)
+ activejob (= 8.0.0.beta1)
+ activemodel (= 8.0.0.beta1)
+ activerecord (= 8.0.0.beta1)
+ activestorage (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
bundler (>= 1.15.0)
- railties (= 8.0.0.alpha)
- railties (8.0.0.alpha)
- actionpack (= 8.0.0.alpha)
- activesupport (= 8.0.0.alpha)
+ railties (= 8.0.0.beta1)
+ railties (8.0.0.beta1)
+ actionpack (= 8.0.0.beta1)
+ activesupport (= 8.0.0.beta1)
irb (~> 1.13)
rackup (>= 1.0.0)
rake (>= 12.2)
@@ -98,7 +99,7 @@ GIT
GIT
remote: https://github.com/thoughtbot/appraisal.git
- revision: c83f8376d8f1024d999433010cf81948d56b937e
+ revision: 24feeea4c5c1d2e7a5f95d053da61858c6bfb2b1
specs:
appraisal (2.5.0)
bundler
@@ -108,7 +109,7 @@ GIT
PATH
remote: ..
specs:
- pay (8.0.0)
+ pay (8.1.0)
rails (>= 6.0.0)
GEM
@@ -118,9 +119,10 @@ GEM
public_suffix (>= 2.0.2, < 7.0)
ast (2.4.2)
base64 (0.2.0)
+ benchmark (0.3.0)
bigdecimal (3.1.8)
bindex (0.8.1)
- braintree (4.21.0)
+ braintree (4.22.0)
builder (>= 3.2.4)
rexml (>= 3.1.9)
builder (3.3.0)
@@ -141,14 +143,14 @@ GEM
globalid (1.2.1)
activesupport (>= 6.1)
hashdiff (1.1.1)
- i18n (1.14.5)
+ i18n (1.14.6)
concurrent-ruby (~> 1.0)
importmap-rails (2.0.1)
actionpack (>= 6.0.0)
activesupport (>= 6.0.0)
railties (>= 6.0.0)
io-console (0.7.2)
- irb (1.14.0)
+ irb (1.14.1)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
json (2.7.2)
@@ -174,7 +176,7 @@ GEM
mysql2 (0.5.6)
net-http (0.4.1)
uri
- net-imap (0.4.15)
+ net-imap (0.4.16)
date
net-protocol
net-pop (0.1.2)
@@ -190,14 +192,16 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
- paddle (2.5.1)
- faraday (~> 2.0)
+ ostruct (0.6.0)
+ paddle (2.6.0)
+ faraday (~> 2.11.0)
+ ostruct (~> 0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
ast (~> 2.4.1)
racc
pdf-core (0.10.0)
- pg (1.5.7)
+ pg (1.5.8)
prawn (2.5.0)
matrix (~> 0.4)
pdf-core (~> 0.10.0)
@@ -207,7 +211,7 @@ GEM
psych (5.1.2)
stringio
public_suffix (6.0.1)
- puma (6.4.2)
+ puma (6.4.3)
nio4r (~> 2.0)
racc (1.8.1)
rack (3.1.7)
@@ -233,9 +237,9 @@ GEM
prawn (>= 1.3.0, < 3.0.0)
prawn-table (~> 0.2.1)
regexp_parser (2.9.2)
- reline (0.5.9)
+ reline (0.5.10)
io-console (~> 0.5)
- rexml (3.3.7)
+ rexml (3.3.8)
rubocop (1.65.1)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
@@ -247,7 +251,7 @@ GEM
rubocop-ast (>= 1.31.1, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
- rubocop-ast (1.32.2)
+ rubocop-ast (1.32.3)
parser (>= 3.3.1.0)
rubocop-performance (1.21.1)
rubocop (>= 1.48.1, < 2.0)
@@ -262,9 +266,9 @@ GEM
actionpack (>= 6.1)
activesupport (>= 6.1)
sprockets (>= 3.0.0)
- sqlite3 (2.0.4-arm64-darwin)
- sqlite3 (2.0.4-x86_64-darwin)
- sqlite3 (2.0.4-x86_64-linux-gnu)
+ sqlite3 (2.1.0-arm64-darwin)
+ sqlite3 (2.1.0-x86_64-darwin)
+ sqlite3 (2.1.0-x86_64-linux-gnu)
standard (1.40.0)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.0)
@@ -280,18 +284,17 @@ GEM
stimulus-rails (1.3.4)
railties (>= 6.0.0)
stringio (3.1.1)
- stripe (12.5.0)
+ stripe (13.0.0)
thor (1.3.2)
timeout (0.4.1)
ttfunk (1.8.0)
bigdecimal (~> 3.1)
- turbo-rails (2.0.6)
+ turbo-rails (2.0.10)
actionpack (>= 6.0.0)
- activejob (>= 6.0.0)
railties (>= 6.0.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
- unicode-display_width (2.5.0)
+ unicode-display_width (2.6.0)
uri (0.13.1)
useragent (0.16.10)
vcr (6.3.1)
@@ -301,11 +304,11 @@ GEM
activemodel (>= 6.0.0)
bindex (>= 0.4.0)
railties (>= 6.0.0)
- webmock (3.23.1)
+ webmock (3.24.0)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
- webrick (1.8.1)
+ webrick (1.8.2)
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
@@ -331,7 +334,7 @@ DEPENDENCIES
net-imap
net-pop
net-smtp
- paddle (~> 2.4)
+ paddle (~> 2.6)
pay!
pg
prawn
@@ -342,7 +345,7 @@ DEPENDENCIES
sqlite3 (~> 2.0)
standard
stimulus-rails
- stripe (~> 12.0)
+ stripe (~> 13.0)
turbo-rails
vcr
web-console
diff --git a/lib/pay/stripe.rb b/lib/pay/stripe.rb
index f3469b1c..a16cef68 100644
--- a/lib/pay/stripe.rb
+++ b/lib/pay/stripe.rb
@@ -27,7 +27,7 @@ module Webhooks
extend Env
- REQUIRED_VERSION = "~> 12"
+ REQUIRED_VERSION = "~> 13"
# A list of database model names that include Pay
# Used for safely looking up models with client_reference_id
diff --git a/lib/pay/version.rb b/lib/pay/version.rb
index 229e904a..ef5fc7f0 100644
--- a/lib/pay/version.rb
+++ b/lib/pay/version.rb
@@ -1,3 +1,3 @@
module Pay
- VERSION = "8.0.0"
+ VERSION = "8.1.0"
end
diff --git a/test/models/pay/webhook_test.rb b/test/models/pay/webhook_test.rb
index a750d857..790a2739 100644
--- a/test/models/pay/webhook_test.rb
+++ b/test/models/pay/webhook_test.rb
@@ -4,10 +4,15 @@ class Pay::Webhook::Test < ActiveSupport::TestCase
test "rehydrates a Paddle Classic event" do
pay_webhook = Pay::Webhook.create processor: :paddle_classic, event_type: :example, event: json_fixture("paddle_classic/subscription_payment_succeeded")
event = pay_webhook.rehydrated_event
- assert_equal OpenStruct, event.class
assert_equal "visa", event.payment_method.card_type
end
+ test "rehydrates a Paddle Billing event" do
+ pay_webhook = Pay::Webhook.create processor: :paddle_billing, event_type: :example, event: json_fixture("paddle_billing/subscription.created")
+ event = pay_webhook.rehydrated_event
+ assert_equal "month", event.billing_cycle.interval
+ end
+
test "rehydrates a Stripe event" do
pay_webhook = Pay::Webhook.create processor: :stripe, event_type: :example, event: json_fixture("stripe/customer.updated")
event = pay_webhook.rehydrated_event
diff --git a/test/pay/lemon_squeezy/webhooks_test.rb b/test/pay/lemon_squeezy/webhooks_test.rb
index 681e9e8f..1f791aa1 100644
--- a/test/pay/lemon_squeezy/webhooks_test.rb
+++ b/test/pay/lemon_squeezy/webhooks_test.rb
@@ -8,7 +8,7 @@ class Pay::LemonSqueezy::WebhooksTest < ActiveSupport::TestCase
user = users(:none)
user.set_payment_processor :lemon_squeezy, processor_id: event.customer_id
- ::LemonSqueezy::Subscription.expects(:list).returns(OpenStruct.new({data: []}))
+ ::LemonSqueezy::Subscription.expects(:list).returns(ActiveSupport::InheritableOptions.new({data: []}))
assert_difference "Pay::Charge.count" do
Pay::LemonSqueezy::Webhooks::Order.new.call(event)
diff --git a/test/pay/paddle_classic/webhooks/subscription_cancelled_test.rb b/test/pay/paddle_classic/webhooks/subscription_cancelled_test.rb
index b77e24ae..bbc4c8ce 100644
--- a/test/pay/paddle_classic/webhooks/subscription_cancelled_test.rb
+++ b/test/pay/paddle_classic/webhooks/subscription_cancelled_test.rb
@@ -2,17 +2,17 @@
class Pay::PaddleClassic::Webhooks::SubscriptionCancelledTest < ActiveSupport::TestCase
setup do
- @data = OpenStruct.new json_fixture("paddle_classic/subscription_cancelled")
+ @data = paddle_classic_event("subscription_cancelled")
@pay_customer = pay_customers(:paddle_classic)
@pay_customer.update(processor_id: @data.user_id)
end
test "it sets ends_at on the subscription" do
- @pay_customer.subscription.update!(processor_id: @data["subscription_id"])
+ @pay_customer.subscription.update!(processor_id: @data.subscription_id)
Pay::Subscription.any_instance.expects(:update!).with(
status: :canceled,
trial_ends_at: nil,
- ends_at: Time.zone.parse(@data["cancellation_effective_date"])
+ ends_at: Time.zone.parse(@data.cancellation_effective_date)
)
Pay::PaddleClassic::Webhooks::SubscriptionCancelled.new.call(@data)
end
@@ -22,7 +22,7 @@ class Pay::PaddleClassic::Webhooks::SubscriptionCancelledTest < ActiveSupport::T
@data = paddle_classic_event("subscription_cancelled", overrides: {
cancellation_effective_date: 1.month.from_now.to_formatted_s(:db)
})
- @pay_customer.subscription.update!(processor_id: @data["subscription_id"])
+ @pay_customer.subscription.update!(processor_id: @data.subscription_id)
Pay::Subscription.any_instance.expects(:update!).with(
status: :active,
trial_ends_at: nil,
@@ -32,7 +32,7 @@ class Pay::PaddleClassic::Webhooks::SubscriptionCancelledTest < ActiveSupport::T
end
test "it sets trial_ends_at on subscription with trial" do
- @pay_customer.subscription.update!(processor_id: @data["subscription_id"], trial_ends_at: 1.month.ago)
+ @pay_customer.subscription.update!(processor_id: @data.subscription_id, trial_ends_at: 1.month.ago)
Pay::Subscription.any_instance.expects(:update!).with(
status: :canceled,
trial_ends_at: Time.zone.parse(@data["cancellation_effective_date"]),
diff --git a/test/pay/paddle_classic/webhooks/subscription_created_test.rb b/test/pay/paddle_classic/webhooks/subscription_created_test.rb
index 455892ec..b90da069 100644
--- a/test/pay/paddle_classic/webhooks/subscription_created_test.rb
+++ b/test/pay/paddle_classic/webhooks/subscription_created_test.rb
@@ -2,7 +2,7 @@
class Pay::PaddleClassic::Webhooks::SubscriptionCreatedTest < ActiveSupport::TestCase
setup do
- @data = OpenStruct.new json_fixture("paddle_classic/subscription_created")
+ @data = paddle_classic_event("subscription_created")
@user = users(:paddle_classic)
end
diff --git a/test/pay/paddle_classic/webhooks/subscription_payment_refunded_test.rb b/test/pay/paddle_classic/webhooks/subscription_payment_refunded_test.rb
index 6fd445d1..9d0ac7c2 100644
--- a/test/pay/paddle_classic/webhooks/subscription_payment_refunded_test.rb
+++ b/test/pay/paddle_classic/webhooks/subscription_payment_refunded_test.rb
@@ -2,7 +2,7 @@
class Pay::PaddleClassic::Webhooks::SubscriptionPaymentRefundedTest < ActiveSupport::TestCase
setup do
- @data = OpenStruct.new json_fixture("paddle_classic/subscription_payment_refunded")
+ @data = paddle_classic_event("subscription_payment_refunded")
@pay_customer = pay_customers(:paddle_classic)
@pay_customer.update(processor_id: @data.user_id)
end
diff --git a/test/pay/paddle_classic/webhooks/subscription_payment_succeeded_test.rb b/test/pay/paddle_classic/webhooks/subscription_payment_succeeded_test.rb
index dbc3aa51..a63bd690 100644
--- a/test/pay/paddle_classic/webhooks/subscription_payment_succeeded_test.rb
+++ b/test/pay/paddle_classic/webhooks/subscription_payment_succeeded_test.rb
@@ -2,7 +2,7 @@
class Pay::PaddleClassic::Webhooks::SubscriptionPaymentSucceededTest < ActiveSupport::TestCase
setup do
- @data = OpenStruct.new json_fixture("paddle_classic/subscription_payment_succeeded")
+ @data = paddle_classic_event("subscription_payment_succeeded")
@pay_customer = pay_customers(:paddle_classic)
@pay_customer.update(processor_id: @data.user_id)
end
diff --git a/test/pay/paddle_classic/webhooks/subscription_updated_test.rb b/test/pay/paddle_classic/webhooks/subscription_updated_test.rb
index a9f27185..203347ce 100644
--- a/test/pay/paddle_classic/webhooks/subscription_updated_test.rb
+++ b/test/pay/paddle_classic/webhooks/subscription_updated_test.rb
@@ -2,7 +2,7 @@
class Pay::PaddleClassic::Webhooks::SubscriptionUpdatedTest < ActiveSupport::TestCase
setup do
- @data = OpenStruct.new json_fixture("paddle_classic/subscription_updated")
+ @data = paddle_classic_event("subscription_updated")
@pay_customer = pay_customers(:paddle_classic)
@pay_customer.update(processor_id: @data.user_id)
@pay_customer.subscription.update(processor_id: @data.subscription_id)
diff --git a/test/pay/payment_test.rb b/test/pay/payment_test.rb
index 9ebd113c..d6a6c119 100644
--- a/test/pay/payment_test.rb
+++ b/test/pay/payment_test.rb
@@ -2,7 +2,7 @@
class Pay::Payment::Test < ActiveSupport::TestCase
test "amount_with_currency" do
- fake_payment_intent = OpenStruct.new(amount: 12_34, currency: "usd")
+ fake_payment_intent = ActiveSupport::InheritableOptions.new(amount: 12_34, currency: "usd")
assert_equal "$12.34", Pay::Payment.new(fake_payment_intent).amount_with_currency
end
end
diff --git a/test/pay/stripe/webhooks/checkout_session_completed_test.rb b/test/pay/stripe/webhooks/checkout_session_completed_test.rb
index 4e3c5847..f8b653e9 100644
--- a/test/pay/stripe/webhooks/checkout_session_completed_test.rb
+++ b/test/pay/stripe/webhooks/checkout_session_completed_test.rb
@@ -20,7 +20,7 @@ class Pay::Stripe::Webhooks::CheckoutSessionCompletedTest < ActiveSupport::TestC
test "checkout session completed syncs latest charge" do
event = stripe_event("checkout.session.completed", overrides: {"object" => {"payment_intent" => "pi_1234", "latest_charge" => "ch_1234", "subscription" => nil}})
- ::Stripe::PaymentIntent.expects(:retrieve).returns(OpenStruct.new(id: "pi_1234", latest_charge: OpenStruct.new(id: "ch_1234")))
+ ::Stripe::PaymentIntent.expects(:retrieve).returns(::Stripe::PaymentIntent.construct_from(id: "pi_1234", latest_charge: ::Stripe::Charge.construct_from(id: "ch_1234")))
Pay::Stripe::Charge.expects(:sync)
assert_no_difference "Pay::Customer.count" do
Pay::Stripe::Webhooks::CheckoutSessionCompleted.new.call(event)
diff --git a/test/pay/stripe/webhooks/customer_updated_test.rb b/test/pay/stripe/webhooks/customer_updated_test.rb
index 11da759d..88aa713b 100644
--- a/test/pay/stripe/webhooks/customer_updated_test.rb
+++ b/test/pay/stripe/webhooks/customer_updated_test.rb
@@ -7,7 +7,7 @@ class Pay::Stripe::Webhooks::CustomerUpdatedTest < ActiveSupport::TestCase
test "removes default payment method if default payment method set to null" do
event = stripe_event("customer.updated")
- Pay::Stripe::Customer.any_instance.expects(:api_record).returns(OpenStruct.new(invoice_settings: OpenStruct.new(default_payment_method: nil)))
+ Pay::Stripe::Customer.any_instance.expects(:api_record).returns(::Stripe::Customer.construct_from(invoice_credit_balance: Stripe::Util.convert_to_stripe_object({usd: 12345}), invoice_settings: Stripe::Util.convert_to_stripe_object({default_payment_method: nil}), currency: "usd"))
assert_not_nil @pay_customer.default_payment_method
Pay::Stripe::Webhooks::CustomerUpdated.new.call(event)
@pay_customer.reload
@@ -22,7 +22,7 @@ class Pay::Stripe::Webhooks::CustomerUpdatedTest < ActiveSupport::TestCase
test "stripe invoice credit balance is updated" do
event = stripe_event("customer.updated")
- Pay::Stripe::Customer.any_instance.expects(:api_record).returns(OpenStruct.new(invoice_credit_balance: Stripe::Util.convert_to_stripe_object(usd: 12345), invoice_settings: OpenStruct.new(default_payment_method: nil), currency: "usd"))
+ Pay::Stripe::Customer.any_instance.expects(:api_record).returns(::Stripe::Customer.construct_from(invoice_credit_balance: Stripe::Util.convert_to_stripe_object({usd: 12345}), invoice_settings: Stripe::Util.convert_to_stripe_object({default_payment_method: nil}), currency: "usd"))
Pay::Stripe::Webhooks::CustomerUpdated.new.call(event)
@pay_customer.reload
assert_equal "usd", @pay_customer.currency
diff --git a/test/pay/stripe/webhooks/payment_method_updated_test.rb b/test/pay/stripe/webhooks/payment_method_updated_test.rb
index 52a95144..3cd4d3f2 100644
--- a/test/pay/stripe/webhooks/payment_method_updated_test.rb
+++ b/test/pay/stripe/webhooks/payment_method_updated_test.rb
@@ -9,10 +9,10 @@ class Pay::Stripe::Webhooks::PaymentMethodUpdatedTest < ActiveSupport::TestCase
payment_method = pay_payment_methods(:one)
# Spoof Stripe PaymentMethod lookup
- fake_payment_method = OpenStruct.new(id: payment_method.processor_id, customer: "cus_1234", type: "card", card: OpenStruct.new(brand: "Visa", last4: "4242", exp_month: "01", exp_year: "2034"))
+ fake_payment_method = ::Stripe::PaymentMethod.construct_from(id: payment_method.processor_id, customer: "cus_1234", type: "card", card: Stripe::Util.convert_to_stripe_object({brand: "Visa", last4: "4242", exp_month: "01", exp_year: "2034"}))
::Stripe::PaymentMethod.expects(:retrieve).returns(fake_payment_method)
- fake_customer = OpenStruct.new(invoice_settings: OpenStruct.new(default_payment_method: nil))
+ fake_customer = ::Stripe::Customer.construct_from(invoice_settings: Stripe::Util.convert_to_stripe_object({default_payment_method: nil}))
::Stripe::Customer.expects(:retrieve).returns(fake_customer)
assert_equal payment_method.exp_year, payment_method.exp_year
diff --git a/test/test_helper.rb b/test/test_helper.rb
index e0922163..be8795bf 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -68,11 +68,11 @@ def braintree_event(name)
end
def paddle_billing_event(name)
- OpenStruct.new json_fixture("paddle_billing/#{name}")
+ ActiveSupport::InheritableOptions.new json_fixture("paddle_billing/#{name}").deep_symbolize_keys
end
def paddle_classic_event(name, overrides: {})
- OpenStruct.new json_fixture("paddle_classic/#{name}").deep_merge(overrides)
+ ActiveSupport::InheritableOptions.new json_fixture("paddle_classic/#{name}").deep_merge(overrides).deep_symbolize_keys
end
def stripe_event(name, overrides: {})