department-of-veterans-affairs / va.gov-team

Public resources for building on and in support of VA.gov. Visit complete Knowledge Hub:
https://depo-platform-documentation.scrollhelp.site/index.html
281 stars 197 forks source link

FE/BE Pair - Discovery - getCalculatedMonthlyIncomeApi failed in helper: #87486

Closed amponce closed 4 weeks ago

amponce commented 1 month ago

Discovery FE/BE pair investigation

Sentry Error

We're seeing an error in sentry that originates from the Additional Income List

getCalculatedMonthlyIncomeApi failed in helper: Error: No value destructured in response from getCalculatedMonthlyIncomeApi calculateTotalAnnualIncome

Acceptance Criteria

OptionSelect commented 1 month ago

Ongoing discussion in debt-devs-internal here in which suggested solution is BE null check added to the total_monthly_net_income variable calculation in income_calculator.rb in API section.

OptionSelect commented 1 month ago

BE PR was merged here. Still testing on our end and monitoring sentry but this should fix this.

OptionSelect commented 1 month ago

FYI the BE PR has yet to be deployed. Still monitoring. No luck reproducing in staging or locally still. I'd like to think we're ok.

Tom-Davis commented 1 month ago

@OptionSelect can you move this to the proper column state (Maybe closed?)

OptionSelect commented 1 month ago

Sorry, still not closed. Rolling due to not having a backend deployment by our devops team since last week. The code change has yet to reach production for us to verify we no longer see the error.

OptionSelect commented 1 month ago

Cant tell if this has been deployed correctly as we are still seeing issues in sentry. Andrew raised concern about calculation so are back to diving in on this as!

Dr-Pongo commented 1 month ago

Heyoo, just wanted to drop some updates on this ticket! A portion of these errors may be false positives being caused by a falsy check when destructuring the response from the endpoint. We included a fix that got merged today and should take effect after the deploy. The error message text has changed so we'll need to keep an eye out for the new error:

No value destructured in response from getCalculatedMonthlyIncomeApi in checkIncomeGmt

Going to move to validate until the end of the week as we monitor Sentry

Dr-Pongo commented 4 weeks ago

New error handling and income api calls seems to be clear in sentry. Saw a small single error pop, but does not appear to be indicative of a larger problem we can address. Closing out now that error handling is more robust!