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-20] [$500] 0 member is formatted weirdly when leaving a room and revisiting room details #35358
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor
changed the title [-]`0` member is formatted weirdly when leaving a room and revisiting room details[/-][+][$500] `0` member is formatted weirdly when leaving a room and revisiting room details[/+]on Jan 30, 2024
📣 @jyash97! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
Format:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>
will mean 0 will display as is without any wrapper component.
Because subtitle ?? subtitle === 0 means 0 (because ?? won't care about the second part of the operator if the first part is already not nullish)
Then (0 && <Component means pure 0 as well.
What changes do you think we should make in order to solve the problem?
Should use subtitle || subtitle === 0 like before
We can structure it as
(!!subtitle || (subtitle === 0))
or
subtitle === 0 || subtitle
So that it won't trigger lint error. In here when we check subtitle, that means we're checking if subtitle exists/is truthy, so we should use !!subtitle ||, if we use subtitle || it's similar to coalesing using || and is discouraged by our lint settings.
Even better is to extract it to a shouldShowSubtitle boolean and use it, will be cleaner.
What alternative solutions did you explore? (Optional)
Unrelated but there's another issue where when opening that Member list with 0 member, we'll see an empty Member list, to fix it we might want to:
Option 1:
Do not show right arrow if member count is 0, and make the MenuItem disabled
When the user navigates to the Member list directly via deeplink, automatically go back to previous screen/or show not found page.
Option 2:
Just show a text like There's no member in this room if there's no member
Those are my suggestions, the implementation for it is straight-forward, but I think it should be addressed separately and we need to decide the UX, since it's separate from the issue in OP and has a different root cause.
changed the title [-][$500] `0` member is formatted weirdly when leaving a room and revisiting room details[/-][+][HOLD for payment 2024-02-20] [$500] `0` member is formatted weirdly when leaving a room and revisiting room details[/+]on Feb 13, 2024
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.40-5 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve 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:
[@shubham1206agra] The PR that introduced the bug has been identified. Link to the PR:
[@shubham1206agra] 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:
[@shubham1206agra] 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:
[@shubham1206agra] Determine if we should create a regression test for this bug.
[@shubham1206agra] 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.
[@CortneyOfstad] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
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:
[@shubham1206agra] 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: Not Required
[@shubham1206agra] Determine if we should create a regression test for this bug. No
[@shubham1206agra] 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.
[@CortneyOfstad] Link the GH issue for creating/updating the regression test once above steps have been agreed upon:
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor
Activity
melvin-bot commentedon Jan 30, 2024
Job added to Upwork: https://www.upwork.com/jobs/~018691b573ff8ea80e
[-]`0` member is formatted weirdly when leaving a room and revisiting room details[/-][+][$500] `0` member is formatted weirdly when leaving a room and revisiting room details[/+]melvin-bot commentedon Jan 30, 2024
Triggered auto assignment to @CortneyOfstad (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.melvin-bot commentedon Jan 30, 2024
Triggered auto assignment to Contributor-plus team member for initial proposal review - @shubham1206agra (
External)jyash97 commentedon Jan 30, 2024
Hey 👋🏻
new to contributing to Expensify, is there any way I can take this issue?
melvin-bot commentedon Jan 30, 2024
📣 @jyash97! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Format:
dukenv0307 commentedon Jan 30, 2024
Proposal
Please re-state the problem that we are trying to solve in this issue.
The zero is there but its formatted really strangely
What is the root cause of that problem?
This is regression from f74f3c3#diff-9db0c2baf85f38b9a238d03f1089a686039ab6c6b94ef412bda920293909b7a4
Let's see this line that shows the Members count
will mean
0will display as is without any wrapper component.Because
subtitle ?? subtitle === 0means0(because??won't care about the second part of the operator if the first part is already not nullish)Then
(0 && <Componentmeans pure 0 as well.What changes do you think we should make in order to solve the problem?
Should use
subtitle || subtitle === 0like beforeWe can structure it as
or
So that it won't trigger lint error. In here when we check
subtitle, that means we're checking if subtitle exists/is truthy, so we should use!!subtitle ||, if we usesubtitle ||it's similar to coalesing using||and is discouraged by our lint settings.Even better is to extract it to a
shouldShowSubtitleboolean and use it, will be cleaner.What alternative solutions did you explore? (Optional)
Unrelated but there's another issue where when opening that Member list with
0member, we'll see an empty Member list, to fix it we might want to:Option 1:
Option 2:
There's no member in this roomif there's no memberThose are my suggestions, the implementation for it is straight-forward, but I think it should be addressed separately and we need to decide the UX, since it's separate from the issue in OP and has a different root cause.
jyash97 commentedon Jan 30, 2024
Contributor details
Your Expensify account email: jyash97@gmail.com
Upwork Profile Link: https://www.upwork.com/freelancers/~015f3056aaa4d9252e
melvin-bot commentedon Jan 30, 2024
✅ Contributor details stored successfully. Thank you for contributing to Expensify!
31 remaining items
[-][$500] `0` member is formatted weirdly when leaving a room and revisiting room details[/-][+][HOLD for payment 2024-02-20] [$500] `0` member is formatted weirdly when leaving a room and revisiting room details[/+]melvin-bot commentedon Feb 13, 2024
Reviewinglabel has been removed, please complete the "BugZero Checklist".melvin-bot commentedon Feb 13, 2024
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.4.40-5 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 2024-02-20. 🎊
For reference, here are some details about the assignees on this issue:
melvin-bot commentedon Feb 13, 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:
CortneyOfstad commentedon Feb 14, 2024
Payment is scheduled for next week! 🎉
CortneyOfstad commentedon Feb 20, 2024
@shubham1206agra it looks like we're still waiting for you to accept the proposal in Upwork here — can you let me know once you accept!
@dukenv0307 you have been paid via Upwork, so you are all set!
shubham1206agra commentedon Feb 20, 2024
@CortneyOfstad Accepted.
CortneyOfstad commentedon Feb 20, 2024
Perfect! Payment has been made! Once you have completed the checklist @shubham1206agra — we can get this closed. Thank you!
CortneyOfstad commentedon Feb 21, 2024
@shubham1206agra any chance you can have the checklist completed by EOD today?
shubham1206agra commentedon Feb 21, 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:
CortneyOfstad commentedon Feb 21, 2024
Perfect! Thanks so much!