1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-07-23 15:19:38 +02:00

Implement error handling and logging for sparkline and series methods

- Added rescue blocks to handle exceptions in the Accounts and AccountableSparklines controllers, logging errors and rendering error partials.
- Enhanced error handling in the Account::Chartable and Balance::ChartSeriesBuilder models, logging specific error messages for series generation failures.
- Updated the accounts view to include a timeout for Turbo frame loading.
- Added a test to ensure graceful handling of sparkline errors in the AccountsController.

In reference to bug #2315
This commit is contained in:
Josh Pigford 2025-05-26 20:05:16 -05:00
parent 3cc88f3e98
commit 6f67827f14
9 changed files with 113 additions and 8 deletions

View file

@ -17,6 +17,9 @@ class AccountableSparklinesController < ApplicationController
end
render layout: false
rescue => e
Rails.logger.error "Accountable sparkline error for #{@accountable&.name}: #{e.message}"
render partial: "accountable_sparklines/error", layout: false
end
private