Automatically create a GH when users try to enable travel on non-verified domains#63208
Automatically create a GH when users try to enable travel on non-verified domains#63208youssef-lr merged 15 commits intomainfrom
Conversation
|
@stitesExpensify Does this require C+ review? |
|
I think that we might as well, just to be safe |
|
Reviewing today |
|
@stitesExpensify To clarify, do you need both of us to review or just one reviewer? |
rojiphil
left a comment
There was a problem hiding this comment.
@stitesExpensify The code changes LGTM but I have just one comment. Please have a look.
Also, how do we verify the creation of GH issue?
| navigateToAcceptTerms(CONST.TRAVEL.DEFAULT_DOMAIN); | ||
| } else if (!isBetaEnabled(CONST.BETAS.IS_TRAVEL_VERIFIED)) { | ||
| setVerificationModalVisibility(true); | ||
| requestTravelAccess(); |
There was a problem hiding this comment.
I think we may want to prevent calling TRAVEL_SIGNUP_REQUEST API again once we have successfully requested travel access. We can do this by checking the existence of lastTravelSignupRequestTime. This can help us avoid unnecessary requests to the backend and, also, potential duplicate GH issue creation. What do you think?
@akinwale I think one may be enough but @stitesExpensify can confirm. It looks like the auto-assignment bot failed to assign the PR to me from the assigned issue. |
|
One is enough! Thanks for your review, I'll get that updated |
Reviewer Checklist
Screenshots/VideosAndroid: HybridApp63208-android-hybrid-001.mp4Android: mWeb Chrome63208-mweb-chrome-001.mp4iOS: HybridApp63208-ios-hybrid-001.mp4iOS: mWeb Safari63208-mweb-safari-001.mp4MacOS: Chrome / Safari63208-web-chrome-001.mp4MacOS: Desktop63208-desktop-001.mp4 |
rojiphil
left a comment
There was a problem hiding this comment.
@stitesExpensify Thanks for the update. The changes work well in online scenarios but we will run into problems in offline scenarios. Currently, when offline, all such requests will be queued, and sent once the app comes back online thereby resulting in duplicate requests. The attached video demonstrates this. One way to prevent this is by optimistically setting lastTravelSignupRequestTime. What do you think?
63208-offline-query-001.mp4
|
Hey @rojiphil just pushed up optimistically setting the data! |
@stitesExpensify Thanks. That looks great. One more change we need is to add dependency for |
|
Ah yes, of course. Thank you very much. Updated! |
rojiphil
left a comment
There was a problem hiding this comment.
Thanks @stitesExpensify. LGTM and works great as well.
Just that there are merge conflicts to be resolved. Otherwise, we are good to go.
63208-offline-web-chrome-001.mp4
|
@youssef-lr 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] |
|
✋ 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/youssef-lr in version: 9.1.75-0 🚀
|
|
🚀 Deployed to production by https://github.com/mountiny in version: 9.1.76-5 🚀
|

Explanation of Change
We need to start calling our API to create a Gh issue when users click the travel button
Fixed Issues
$ #63567
PROPOSAL: n/a
Tests
Offline tests
n/a
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))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
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop