Repository navigation
[$500] chat thread report header is incorrectly showing the "root" report in second line rather than the "parent" report. #27986
Description
Activity
- addedDailyKSv2KSv2BugSomething is broken. Auto assigns a BugZero manager.Something is broken. Auto assigns a BugZero manager.
on Sep 22, 2023 Triggered auto assignment to @kevinksullivan (
Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.Bug0 Triage Checklist (Main S/O)
- This "bug" occurs on a supported platform (ensure
Platformsin OP are ✅) - This bug is not a duplicate report (check E/App issues and #expensify-bugs)
- If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
- This bug is reproducible using the reproduction steps in the OP. S/O
- If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
- If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
- This issue is filled out as thoroughly and clearly as possible
- Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
- I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync
- This "bug" occurs on a supported platform (ensure
JmillsExpensify commented
on Sep 22, 2023 ContributorAuthorMore actionsOriginally reported internally in Slack.
Proposal
Please re-state the problem that we are trying to solve in this issue.
chat thread report header is incorrectly showing the "root" report in second line rather than the "parent" report.
What is the root cause of that problem?
In
getRootReportAndWorkspaceNamefunction, we have an infinity loop here to get the root parent report name of the thread reportLines 1743 to 1746 in 8e2edbf
if (isChildReport(report) && !isMoneyRequestReport(report) && !isTaskReport(report)) { const parentReport = lodashGet(allReports, [`${ONYXKEYS.COLLECTION.REPORT}${report.parentReportID}`]); return getRootReportAndWorkspaceName(parentReport); } What changes do you think we should make in order to solve the problem?
We should remove this infinity loop to get the name of the previous parent report of the thread.
Lines 1743 to 1746 in 8e2edbf
if (isChildReport(report) && !isMoneyRequestReport(report) && !isTaskReport(report)) { const parentReport = lodashGet(allReports, [`${ONYXKEYS.COLLECTION.REPORT}${report.parentReportID}`]); return getRootReportAndWorkspaceName(parentReport); } What alternative solutions did you explore? (Optional)
@kevinksullivan Whoops! This issue is 2 days overdue. Let's get this updated quick!
- addedExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributor
on Sep 26, 2023 - changed the title
[-]`chat` thread report header is incorrectly showing the "root" report in second line rather than the "parent" report. [/-][+][$500] `chat` thread report header is incorrectly showing the "root" report in second line rather than the "parent" report. [/+]on Sep 26, 2023 Job added to Upwork: https://www.upwork.com/jobs/~014565dfd91b80271a
- addedHelp WantedApply this label when an issue is open to proposals by contributorsApply this label when an issue is open to proposals by contributors
on Sep 26, 2023 Triggered auto assignment to Contributor-plus team member for initial proposal review - @parasharrajat (
External)22 remaining items
- addedDailyKSv2KSv2InternalRequires API changes or must be handled by Expensify staffRequires API changes or must be handled by Expensify staffand removedWeeklyKSv2KSv2ExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributorHelp WantedApply this label when an issue is open to proposals by contributorsApply this label when an issue is open to proposals by contributors
on Oct 20, 2023 Current assignee @parasharrajat is eligible for the Internal assigner, not assigning anyone new.
@JmillsExpensify Any comments on #27986 (comment)
@kevinksullivan, @parasharrajat Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
@JmillsExpensify @kevinksullivan Do you have any comments on #27986 (comment)?
Agree with @chiragsalian here
Reproduction steps
Upwork Automation - Do Not Edit