notebook/lib/tasks
Andrew Brown ac96a001a8 Fix Stripe subscription errors by migrating deprecated sources API to payment_methods API
- Migrate from deprecated sources API to modern payment_methods API in SubscriptionsController
- Update subscription plan modifications to use Subscription.modify instead of direct assignment
- Fix payment method creation/deletion to use PaymentMethod.create/detach instead of sources
- Update view templates to use new payment_methods data structure
- Migrate price.id usage from deprecated plan.id in data integrity tasks
- Add comprehensive test suite with proper Stripe API stubs
- Add missing test gems: rspec-rails, webmock, factory_bot_rails, shoulda-matchers

This resolves Error 500 when users try to upgrade to Premium subscriptions.
The original error was: NoMethodError - undefined method 'total_count' for nil:NilClass
caused by stripe_customer.sources.total_count when sources API returned nil.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-07-10 23:40:36 -07:00
..
.keep
backfill.rake nasty git merge 2022-05-23 13:49:36 -07:00
billing_plans.rake
cache.rake don't trigger model callbacks on wc cache updates 2022-12-01 19:12:39 -08:00
cleanup.rake
daily.rake some anti-spam measures 2024-03-27 14:15:53 -07:00
data_integrity.rake Fix Stripe subscription errors by migrating deprecated sources API to payment_methods API 2025-07-10 23:40:36 -07:00
data_migrations.rake enable items for basil 2023-03-14 16:18:08 -07:00
datafill.rake
machine_learning.rake
one_off.rake add YiR notif task 2023-12-31 17:42:50 -08:00
page_type.rake
voting.rake