You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[HOLD for payment 2024-02-22] [$500] iOS - Login - The splash screen glitches and flashes on launch #34696
Version Number: 1.4.26.1 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: Email or phone of affected tester (no customers): Logs:https://stackoverflow.com/c/expensify/questions/4856 Expensify/Expensify Issue URL: Issue reported by: Applause - Internal Team Slack conversation:
Action Performed:
Open the iOS app
Kill the app and launch it again
Expected Result:
The splash screen transition should be smooth on launch
Actual Result:
The splash screen glitches and flashes on launch
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
changed the title [-] iOS - Login - The splash screen glitches and flashes on launch[/-][+][$500] iOS - Login - The splash screen glitches and flashes on launch[/+]on Jan 18, 2024
Please re-state the problem that we are trying to solve in this issue
The splash screen hide animation glitches on app launch.
What is the root cause of that problem?
PR #30905 implemented expo-image for rendering of the SVG background image which made the loading process heavier than before when we used react-native-fast-image.
On this issue there are 2 things on the SignInPageLayout which cause the splash screen hide animation glitch - I will list them in order of severity:
The BackgroundImage which on iOS .../BackgroundImage/index.ios.js uses Image from expo-image to load the background image - a large SVG file of ~800kb.
home-background--mobile-new.svg
The .../SignInPageContent/SignInHeroImage.js which is the Lottie Hands animation.
Both of these are being rendered while the .../SplashScreenHider/index.native.tsx component's onLayout calls the splash screen hide function and the callback animates out 2 properties (opacity and scale) of the splash screen background and expensify logo.
What changes do you think we should make in order to solve the problem?
TLDR: Use isSplashHidden from SplashScreenHiddenContext to prevent the rendering of both iOS BackgroundImage and SignInHeroImage Lottie animation until the splash screen is hidden.
Pseudo code:
For .../BackgroundImage/index.ios.js we will show it with a smooth 750ms animation as soon as the splash hides:
check if !isSplashHidden is true and return; in order to prevent the Image rendering (which causes the issue)
below, wrap the Image with Reanimated.View, passing the same styles as Image + animatedStyle
add onLoadEnd prop to the Image where we pass the function that will trigger the animation
this way when isSplashHidden becomes true and the SVG finished loading, it will animate-in nicely.
For .../SplashScreenHider/index.native.tsx we will render an empty View with the Lottie component's styles so that the layout doesn't jump when the actual Lottie component is rendered:
check if !isSplashHidden is true and return the empty View with the Lottie component's styles - by doing this we prevent the rendering of the Lottie component (which causes the issue)
this way when isSplashHidden becomes true only then we render the Lottie component that will display the Hands animation.
📣 @ikevin127 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!
Offer link Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻
Keep in mind: Code of Conduct | Contributing 📖
changed the title [-][$500] iOS - Login - The splash screen glitches and flashes on launch[/-][+][HOLD for payment 2024-02-22] [$500] iOS - Login - The splash screen glitches and flashes on launch[/+]on Feb 22, 2024
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
[@aimane-chnaif] The PR that introduced the bug has been identified. Link to the PR:
[@aimane-chnaif] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
[@aimane-chnaif] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:
[@aimane-chnaif] Determine if we should create a regression test for this bug.
[@aimane-chnaif] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.
[@garrettmknight] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
This is polish rather than bug. And no offending PR, always existed.
Not worth adding regression test. And also caught by QA team. If the bug happens again, easily noticeable on app launch.
Activity
[-] iOS - Login - The splash screen glitches and flashes on launch[/-][+][$500] iOS - Login - The splash screen glitches and flashes on launch[/+]melvin-bot commentedon Jan 18, 2024
Job added to Upwork: https://www.upwork.com/jobs/~01782ced06468ec4f5
melvin-bot commentedon Jan 18, 2024
Triggered auto assignment to @garrettmknight (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.melvin-bot commentedon Jan 18, 2024
Triggered auto assignment to Contributor-plus team member for initial proposal review - @0xmiroslav (
External)lanitochka17 commentedon Jan 18, 2024
#wave9-collect-signup
ikevin127 commentedon Jan 19, 2024
Proposal
Please re-state the problem that we are trying to solve in this issue
The splash screen hide animation glitches on app launch.
What is the root cause of that problem?
PR #30905 implemented
expo-imagefor rendering of the SVG background image which made the loading process heavier than before when we usedreact-native-fast-image.On this issue there are 2 things on the
SignInPageLayoutwhich cause the splash screen hide animation glitch - I will list them in order of severity:BackgroundImagewhich on iOS.../BackgroundImage/index.ios.jsuses Image fromexpo-imageto load the background image - a large SVG file of ~800kb.home-background--mobile-new.svg
.../SignInPageContent/SignInHeroImage.jswhich is the LottieHandsanimation.Both of these are being rendered while the
.../SplashScreenHider/index.native.tsxcomponent's onLayout calls the splash screen hide function and the callback animates out 2 properties (opacity and scale) of the splash screen background and expensify logo.What changes do you think we should make in order to solve the problem?
TLDR: Use
isSplashHiddenfrom SplashScreenHiddenContext to prevent the rendering of both iOSBackgroundImageandSignInHeroImageLottie animation until the splash screen is hidden.Pseudo code:
.../BackgroundImage/index.ios.jswe will show it with a smooth 750ms animation as soon as the splash hides:onLoadEndprop to the Image where we pass the function that will trigger the animationthis way when
isSplashHiddenbecomes true and the SVG finished loading, it will animate-in nicely..../SplashScreenHider/index.native.tsxwe will render an empty View with the Lottie component's styles so that the layout doesn't jump when the actual Lottie component is rendered:this way when
isSplashHiddenbecomes true only then we render the Lottie component that will display the Hands animation.Videos (included slow motion)
iOS: Native
Screen.Recording.2024-01-19.at.02.03.38.mov
Screen.Recording.2024-01-19.at.02.03.38.mp4
garrettmknight commentedon Jan 22, 2024
@0xmiroslav what do you think of this first proposal?
19 remaining items
melvin-bot commentedon Jan 25, 2024
📣 @aimane-chnaif 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app!
Offer link
Upwork job
melvin-bot commentedon Jan 25, 2024
📣 @ikevin127 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!
Offer link
Upwork job
Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑💻
Keep in mind: Code of Conduct | Contributing 📖
ikevin127 commentedon Jan 25, 2024
PR #35185 ready for review! 🚀
cc @aimane-chnaif
ikevin127 commentedon Feb 15, 2024
Looks like the automation might've failed to set the 7-day hold for payment since the PR #35185 (comment) was deployed to production ~4 hours ago 🧐
Hold for payment date should be:
2024-02-22
cc @garrettmknight
aimane-chnaif commentedon Feb 15, 2024
Looks like all automations were failed in this deploy cycle
[-][$500] iOS - Login - The splash screen glitches and flashes on launch[/-][+][HOLD for payment 2024-02-22] [$500] iOS - Login - The splash screen glitches and flashes on launch[/+]garrettmknight commentedon Feb 22, 2024
Paid!
garrettmknight commentedon Feb 22, 2024
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
garrettmknight commentedon Feb 22, 2024
@aimane-chnaif can you complete the checklist when you get a chance?
aimane-chnaif commentedon Feb 22, 2024
This is polish rather than bug. And no offending PR, always existed.
Not worth adding regression test. And also caught by QA team. If the bug happens again, easily noticeable on app launch.