Add 434 to broken connection ignored statuses for card feeds#84803
Add 434 to broken connection ignored statuses for card feeds#84803
Conversation
Card-specific error 434 (account not found) should not mark the entire feed as broken. Also align getFeedConnectionBrokenCard to use the same BROKEN_CONNECTION_IGNORED_STATUSES allowlist for consistency. Co-authored-by: Carlos Miceli <carlosmiceli@users.noreply.github.com>
Co-authored-by: Carlos Miceli <carlosmiceli@users.noreply.github.com>
|
@carlosmiceli Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Co-authored-by: Carlos Miceli <carlosmiceli@users.noreply.github.com>
|
Fixed the failing Prettier check: the callback in |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
@situchan ready for you, should be a quick one |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb Safari |
| } | ||
|
|
||
| return Object.values(feedCards).find((card) => !isEmptyObject(card) && card.bank !== feedToExclude && card.lastScrapeResult !== 200); | ||
| return Object.values(feedCards).find((card) => !isEmptyObject(card) && card.bank !== feedToExclude && isCardConnectionBroken(card)); |
There was a problem hiding this comment.
@MelvinBot can you add unit test for getFeedConnectionBrokenCard?
There was a problem hiding this comment.
Added 9 unit tests for getFeedConnectionBrokenCard covering:
- undefined / empty feedCards
- card with a broken connection status (e.g. 403)
- cards with ignored statuses only (200, 434)
- cards with no
lastScrapeResult feedToExcludefiltering- empty card objects being skipped
All tests pass locally (da2d66f).
Co-authored-by: Situ Chandra Shil <situchan@users.noreply.github.com>
|
@MelvinBot fix failing tests |
Co-authored-by: Carlos Miceli <carlosmiceli@users.noreply.github.com>
|
Fixed the failing typecheck: the test card objects in |
The test card objects are missing required Card properties (domainName, lastUpdated, fraud), so a direct 'as Card' cast fails. Using 'as unknown as Card' matches the pattern used in the rest of the file. Co-authored-by: Carlos Miceli <carlosmiceli@users.noreply.github.com>
…te' into claude-fixChaseCardFeedBrokenState Co-authored-by: Carlos Miceli <carlosmiceli@users.noreply.github.com>
|
Fixed the failing typecheck: changed |
|
@carlosmiceli After adding 434 to ignored statuses, we no longer show broken connection error for
|
Yes, that's to be expected since I believe that function is for seeing errors we should actually see in the UI. |
|
@deetergp pulled you in to just review/merge, since I co-authored a commit here, thanks sir 🙇 |
|
@carlosmiceli Roger, wilco! |
|
🚧 @deetergp has triggered a test Expensify/App build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
@carlosmiceli @situchan @deetergp Can this one please be tested internally, We can't add Chase cards and unable to trigger connection error from our end |
|
🚀 Deployed to staging by https://github.com/deetergp in version: 9.3.37-0 🚀
|
|
🚀 Deployed to production by https://github.com/cristipaval in version: 9.3.37-10 🚀
|





Explanation of Change
NewDot incorrectly marks the entire Chase company card feed as "broken" when individual cards have error 434 ("account not found"). This is a card-specific error (e.g., a closed/removed bank account) that should not cause the feed-level broken connection UI.
Changes:
434toBROKEN_CONNECTION_IGNORED_STATUSESinCONST/index.tsso card-specific "account not found" errors no longer trigger the feed-level broken connection state.getFeedConnectionBrokenCard()inCardUtils.tsto use the sameBROKEN_CONNECTION_IGNORED_STATUSESallowlist instead of a hardcoded!== 200check, ensuring consistency withisCardConnectionBroken().Fixed Issues
$ #83372
PROPOSAL: #83372 (comment)
Tests
lastScrapeResult = 434(account not found)lastScrapeResult = 403)Offline tests
N/A — this change only affects how scrape result statuses are classified. No network requests are made or modified.
QA Steps
lastScrapeResult = 434PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
N/A — logic-only change, no UI modifications
Android: mWeb Chrome
N/A — logic-only change, no UI modifications
iOS: Native
N/A — logic-only change, no UI modifications
iOS: mWeb Safari
N/A — logic-only change, no UI modifications
MacOS: Chrome / Safari
N/A — logic-only change, no UI modifications