-
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
[HOLD for payment 2023-11-30] [$500] Composer is very large on first render #31089
Comments
Triggered auto assignment to @strepanier03 ( |
Bug0 Triage Checklist (Main S/O)
|
Triggered auto assignment to @srikarparsi ( |
@srikarparsi - Could you please help me test this on DEV? I don't have access to a DEV environment. |
Thank you @MonilBhavsar 🙌 |
Job added to Upwork: https://www.upwork.com/jobs/~01b525aa9327716a48 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @0xmiroslav ( |
@MonilBhavsar Unable to repro this. Can you check your |
Specifically, |
ProposalPlease re-state the problem that we are trying to solve in this issue.Note: this is now reproducible in production. Given:
Observe: The composer is expanded by default, rather than collapsed. Steps to repro consistently:
To repeat without logging out and in again: These steps work once per report. When the report initially loads and the bug is triggered, the bug won't reoccur in that report until the user logs out and back in (explanation below). What is the root cause of that problem?Summary (tl;dr)Under specific conditions, we're using The bug is absent with Details
What changes do you think we should make in order to solve the problem?This needs to be fixed upstream, but the risk of the upstream change feels elevated, and reverting the offending commit may cause other issues. In the interest of getting a quick fix into production for this specific bug:
App/src/pages/home/ReportScreen.js Lines 128 to 131 in 04b5fa4
We should update return String(lodashGet(route, 'params.reportID') || null); This is simply ensuring that the current intended behavior - returning a string of value "null" - happens for any falsy report id value. What alternative solutions did you explore?Here are two other fixes that work just as well, and are legitimate fixes to unintended behavior in their own right. However it's possible that some parts of the app may be unintentionally relying on the current behavior. That said, both of these corrections should be made. Alternative 1
App/src/pages/home/ReportScreen.js Lines 224 to 230 in 04b5fa4
Limiting the dependency to the report ID keeps the memoized value from updating when the second rehydration occurs (part 4 in the root cause above), and stops the unintended collection key from being used when accessing composer full size state. We should update Alternative 2Again looking at part 4 of the root cause above, our deep linking logic shouldn't push a route if there is no route, as it only serves to rerun the last active report redirect that App/src/libs/actions/Report.js Line 2016 in 04b5fa4
We should return before we hit this line if Alternative 3We also have the option of reverting the PR in onyx that caused the regression, but that will likely cause other regressions - I'd recommend a forward looking solution rather than a revert there. |
I believe this is a recent regression. I started experiencing this just about 2 weeks ago. |
Proposal@0xmiroslav proposal rewritten. Note that this is now in production. |
ProposalPlease re-state the problem that we are trying to solve in this issue.The composer is full-size on the first render What is the root cause of that problem?In this PR, we always return an object when the key is a collection key. In the past, we will return as On the first render, this key doesn't exist in Onyx so Other keys like What changes do you think we should make in order to solve the problem?In
And update this prop to App/src/pages/home/ReportScreen.js Line 442 in 77be80b
What alternative solutions did you explore? (Optional)In |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
@tgolen makes sense, I can swap |
OK, thanks! I wanted to give a quick warning that I believe I tried that once and then it broke several of the other references to |
@cead22 I'm ready to get a PR up once assigned. |
📣 @0xmiroslav 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app! |
📣 @erquhart 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app! Offer link |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.2-3 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue: If no regressions arise, payment will be issued on 2023-11-30. 🎊 After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
For reference, here are some details about the assignees on this issue: |
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:
|
@strepanier03 bumping for payment |
Yep, this just came off payment hold yesterday so I'm taking care of it today. Didn't have the time to handle it yesterday. |
@erquhart - You're paid out and the contract closed, thank you again for your work and involvement with our community. @0xmiroslav - Please post the checklist items as soon as you have time and I'll finish up then close. |
The regression was from Onyx repo, but after discussion, it's expected, so needed to fix on app side. |
Gotcha, thanks @0xmiroslav - I've finished paying this out and I'm going to close now. |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: DEV
Reproducible in staging?: DEV
Reproducible in production?: DEV
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: @marcaaron
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1699488803622289
Action Performed:
Expected Result:
Minimized composer
Actual Result:
Giant composer appears
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: