-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix GBR and error briefly show after connecting to QBO, Xero. #47483
Conversation
Hold for #44148 (comment) |
This should be ready for your review @war-in and @arosiclair . I'll complete the rest of the screenshots/videos tomorrow morning. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM so far
Completed the screenshots/videos. |
@hungvu193 @arosiclair should i review this or it's handled as part of a project with someone else? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, only one question
Please hold your review. I think this PR is a follow-up of our current issue that we're working on 😄 |
Nope this shouldn't be held on anything. We need to fix #44148. Please fix the new conflicts and then review @hungvu193 @getusha. |
I am not suggesting that. the condition is returning early if you look closely. |
I mean, checking Nevermind, can you please use |
Of course it will appear to work since we are not showing an error when the last sync isn't a success based on your recent change. if (isSyncInProgress || isEmptyObject(connection?.lastSync) || connection?.lastSync?.isSuccessful === false) {
Why do we want to show an empty error message? |
If App/src/pages/workspace/accounting/PolicyAccountingPage.tsx Lines 74 to 79 in 0c84552
Damn, that's bad merge, I'll update it shortly |
As I checked the logs, |
What steps did you take to reproduce and with what integration? |
Here is the steps:
|
I can also reproduce this on Staging. [info] [Report] Handled multipleEvents event sent by Pusher - {"updates":[{"data":[{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"enableNewCategories":true}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"export":{"billDate":"LAST_EXPENSE","billStatus":{"purchase":"AWT_PAYMENT","sales":"AWT_PAYMENT"},"billable":"SALES_INVOICE","exporter":"visaocuoitroi193+10@gmail.com","nonReimbursable":"BANK_TRANSACTION","nonReimbursableAccount":"","reimbursable":"BILL"}}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"importCustomers":true}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"importTaxRates":false}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"importTrackingCategories":true}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"isConfigured":false}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"mappings":{"customer":"DEFAULT"}}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"sync":{"hasChosenAutoSyncOption":true,"hasChosenSyncReimbursedReportsOption":true,"invoiceCollectionsAccountID":"","reimbursementAccountID":"","syncReimbursedReports":true}}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"data":{"bankAccounts":[],"revenueAccounts":[],"trackingCategories":[]}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"lastSync":{"errorDate":"","errorMessage":"","isAuthenticationError":false,"isConnected":false,"isSuccessful":false,"source":"","successfulDate":""}}}}}],"eventType":"onyxApiUpdate"}],"lastUpdateID":1408169430,"previousUpdateID":1408168356}
Log.ts:75 [info] [Report] Handled multipleEvents event sent by Pusher - {"updates":[{"data":[{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"credentials":{"access_token":"OmVpg4a8+OCf9P7I4AoGEQjJuPpM7WqJsxmSjFPUuXAd8nNZT9+rsoVIaUunZVCQODVl7qwM4Lx4iWyF55eY+w/ZUbliljsniSnzeLggWTR/p2h6s6jnw5hxJ1Z+Ngw7U5cdQDim3pQ3/DmJMlG27G8GuQqbALMh6z0A5bjETbtihjB7RbBJl9mCD+wfF+qiA5JC85KAhLhN9k4MsngV8wxG/qoPYUMm2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7ZYcWh5C5LJO1gMzS68OqFyToZ5eNS2sWCojQhl941ntgwk4+gVEBSOO/5xiguEBrueKoc7DbnCz2VH4OI4ojtrnFtLLv2IsCgc/H72nVMEmrrxzmsXU34bC+NEZ/j1kfYO61Q3165zY0NzgA5ih8LXYFFCsVmDigEGG8YbSW4sr3DHw44repa+SrAIoDWNISIotQXPfovVY9AX3pwMm1AHzZJMgy4giAYbBggp1HYWNKplUY8+HT1+hIeV+6/uj/EbSlRmn5XqQFm/2hUVHhOVrRc5Oj0P6QNU0j3pLeehiax0WnUw4z3pXsrdxxGODt31BA8s/rFKeJ+GCXAVPc1wUnVagFS4Iw1eVkGjCXeXUB1sjcJc8fujH0Damy19zjEJLoKFdoM0bYuyn+w5P42DgTfELabJI0/xA3Wv48NT+WsnlGSMvuaTDt6OH2mvHrnb655wA4wKUSRfgGgBjqp4fHhdlq2j2n875zD3AK0v0p6ff2P1A5wMKoLhzFhh1vAiDJNDP+Ogc=;g4JK0vsb1lWz7ThCG1BkFw==;UvDb7btqYTj6s/YOnYff6r7V9RRm+crJgDhevs7b6dMdfswIk4w9MfF0k2smEzptuL+3vGR76o4IYEhRudK3cA=="}}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"config":{"credentials":{"refresh_token":"JKCpcHCKzMY7vOII8mlnSalFw3asTiHWgLZ4Ch07N7gb8/ogBsFknUQO4QKUw+iP;oOIqK5eJp9mrYz/FF7C5vQ==;gl2RaPsH1mkjQ4+0hWe79aSnMrrV607Cl8oU7W5weS+vCzneDUpWrVzD8shomggIvpSp0v/A6eppKCn3dJPSSA=="}}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"data":{"countryCode":"VN"}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"data":{"organisationID":"d98ac19e-d0a4-47ff-b798-e902b46605e5"}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"data":{"revenueAccounts":[{"id":"9ae129c6-f457-4a01-8f6b-1fc1198ebb87","name":"Owner A Drawings"},{"id":"77c628a0-1b47-4c96-ac04-2d810412b0c8","name":"Owner A Funds Introduced"},{"id":"05c8356b-5637-4cdd-b821-de0daab2140f","name":"Owner A Share Capital"}]}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"data":{"tenants":[{"id":"d98ac19e-d0a4-47ff-b798-e902b46605e5","name":"TESST TENANT","value":"!PwkV1"}]}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"lastSync":{"isConnected":true}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"lastSync":{"isSuccessful":true}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"lastSync":{"source":"NEWEXPENSIFY"}}}}},{"key":"policy_57692AA062EC69B3","onyxMethod":"merge","value":{"connections":{"xero":{"lastSync":{"successfulDate":"2024-08-26T14:42:51+0000"}}}}}],"eventType":"onyxApiUpdate"}],"lastUpdateID":1408170694,"previousUpdateID":1408169817} |
Thanks I'm looking into it now. I think I can reproduce as well. |
Add suggestions Co-authored-by: Andrew Rosiclair <arosiclair@gmail.com>
It's working fine after latest changes, @getusha would you mind to retest it? ty 😄 |
little bump @getusha, it's close to merge |
@hungvu193 conflicts to fix here. Thanks! |
Conflicts resolved. This PR should be read for your review again @getusha |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/arosiclair in version: 9.0.28-0 🚀
|
🚀 Deployed to production by https://github.com/roryabraham in version: 9.0.28-3 🚀
|
Details
While connecting to QBO or Xero, we will see an error message briefly at the end of the process, this PR will fix it.
Fixed Issues
$ #44148
#47855
PROPOSAL: N/A
Tests
Connect
button right next to QBO (or Xero).Enter credentials
options, click on that.Offline tests
N/A
QA Steps
Same as Tests.
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Screen.Recording.2024-08-20.at.09.36.21.mov
Android: mWeb Chrome
Screen.Recording.2024-08-20.at.09.27.42.mov
iOS: Native
Screen.Recording.2024-08-20.at.09.32.33.mov
iOS: mWeb Safari
Screen.Recording.2024-08-20.at.09.18.00.mov
MacOS: Chrome / Safari
Screen.Recording.2024-08-19.at.22.14.31.mov
MacOS: Desktop
Screen.Recording.2024-08-19.at.22.32.17.mov