-
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
[No QA] [TS migration] Migrate 'App.js' lib to TypeScript #29661
[No QA] [TS migration] Migrate 'App.js' lib to TypeScript #29661
Conversation
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
# Conflicts: # src/types/onyx/index.ts
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.
Added some smaller comments, lgtm
# Conflicts: # src/libs/Browser/index.web.ts # src/libs/actions/App.ts # src/types/onyx/index.ts
# Conflicts: # src/libs/actions/App.ts
@jjcoffee I guess this PR has run out of your radar, could you take a look at it? |
@VickyStash Ah missed this one, apologies! Added it to my list, will get to it as soon as I can! |
Reviewer Checklist
Screenshots/VideosAndroid: Nativeandroid-native-2023-11-07_15.49.06.mp4Android: mWeb Chromeandroid-chrome-2023-11-07_15.56.30.mp4iOS: Nativeios-native-2023-11-07_15.32.06.mp4iOS: mWeb Safariios-safari-2023-11-07_15.28.20.mp4MacOS: Chrome / Safarimac-chrome-2023-11-07_15.02.25.mp4MacOS: Desktopmac-desktop-2023-11-07_15.19.17.mp4mac-chrome-redirect-2023-11-07_15.18.15.mp4 |
@VickyStash Can you merge main, to see if the performance tests get kicked back into gear? |
@jjcoffee Hm, performance tests are still failing. I will investigate it later. Sorry for the inconvenience! |
@jjcoffee Locally, tests are passed, I'm going to do more investigations tomorrow |
# Conflicts: # src/types/onyx/Response.ts # src/types/onyx/index.ts
@jjcoffee I've merged the main one more time, and performance tests look okay now. |
@VickyStash Nice, thanks! Small tweak for the third test:
Can you change it to something like "when logging in for the first time"? I assumed it meant the redirect would happen from the login page, before logging in. Also I'm getting a crash when testing on that step (this only happens when starting from logged out on the web app): mac-chrome-redirect-2023-11-07_15.07.37.mp4 |
@jjcoffee I was able to reproduce the crash on the main branch as well... |
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!
We did not find an internal engineer to review this PR, trying to assign a random engineer to #24923 as well as to this PR... Please reach out for help on Slack if no one gets assigned! |
Reviewing today |
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.
Two very small things, but good to go. Thank you.
|
||
type Locale = ValueOf<typeof CONST.LOCALES>; | ||
|
||
let currentUserAccountID: number | string; |
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.
NAB: Shouldn't this always be a number and default to null?
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.
@neil-marcellini What do you think about making it to be just a number
and default to 0
. With null
it will require some updates here, like:
[currentUserAccountID ?? '']: {
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.
I don't think 0 is a good default because on my dev environment, and maybe for others, 0 is a special account with email __FAKE__
. So I think null is a better default, or perhaps -1.
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.
You can fix this in a follow up if you like, I'll just merge what we have for now.
✋ 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/neil-marcellini in version: 1.3.98-0 🚀
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.98-5 🚀
|
🚀 Deployed to staging by https://github.com/neil-marcellini in version: 1.3.99-0 🚀
|
🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.99-0 🚀
|
Details
[No QA] [TS migration] Migrate 'App.js' lib to TypeScript
Fixed Issues
$ #24923
PROPOSAL: N/A
Tests
The updated file touches a lot of different functionality, so it makes sense to test the next flows and make sure it works as before:
1
2
3
Test redirect to the desktop app. To be able to test it in DEV, you can temporarily remove this condition
CONFIG.ENVIRONMENT === CONST.ENVIRONMENT.DEV
.Offline tests
QA Steps
The updated file touches a lot of different functionality, so it makes sense to test the next flows and make sure it works as before:
1
2
3
Test redirect to the desktop app. To be able to test it in DEV, you can temporarily remove this condition
CONFIG.ENVIRONMENT === CONST.ENVIRONMENT.DEV
.PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)/** comment above it */
this
properly so there are no scoping issues (i.e. foronClick={this.submit}
the methodthis.submit
should be bound tothis
in the constructor)this
are necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);
ifthis.submit
is never passed to a component event handler likeonClick
)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)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
android.mp4
Android: mWeb Chrome
android.web.mov
iOS: Native
ios.mov
iOS: mWeb Safari
ios.web.mov
MacOS: Chrome / Safari
web.mov
web.reload.mp4
MacOS: Desktop
desktop.mov
desktop.redirect.mov