-
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
[Awaiting C+ for payment][$500] Profile - Private notes doesn't appear on profile when navigate via Share code link #35654
Comments
Job added to Upwork: https://www.upwork.com/jobs/~0145bd5b64b244e0b6 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @shubham1206agra ( |
Triggered auto assignment to @miljakljajic ( |
We think that this bug might be related to #vip-vsb |
ProposalPlease re-state the problem that we are trying to solve in this issue.Private notes doesn't appear on profile when navigate via Share code link What is the root cause of that problem?The problem lies in how we are getting the reportID for the 1to1 chat report here as it depends on the reports list in onyx Lines 281 to 287 in 9d4c634
As getChatByParticipants depends on the reports from onyx if it is not yet fetched from BE when the profile page is rendered it will result in null reportID and privates notes not displayedLines 238 to 239 in 9d4c634
Similarly notification preference is not shown too Lines 135 to 136 in e791ecc
What changes do you think we should make in order to solve the problem?In cases where the report is empty we need to subscribe to the reports collection ( What alternative solutions did you explore? (Optional)We can also think of having the reportID data in the route in that case we don't depend on the |
ProposalPlease re-state the problem that we are trying to solve in this issue.
What is the root cause of that problem?
What changes do you think we should make in order to solve the problem?
so we can pass the
export default compose(
withLocalize,
withOnyx(
{
reports: {
key: ONYXKEYS.COLLECTION.REPORT,
},
personalDetails: {
key: ONYXKEYS.PERSONAL_DETAILS_LIST,
},
session: {
key: ONYXKEYS.SESSION,
},
report: {
+ key: ({route, session, reports}) => {
const accountID = Number(lodashGet(route.params, 'accountID', 0));
+ const reportID = lodashGet(ReportUtils.getChatByParticipants([accountID], reports), 'reportID', '');
if ((session && Number(session.accountID) === accountID) || Session.isAnonymousUser() || !reportID) {
return null;
}
return `${ONYXKEYS.COLLECTION.REPORT}${reportID}`;
},
},
},
),
)(ProfilePage);
What alternative solutions did you explore? (Optional)
+ if (previousKey !== newKey || !this.activeConnectionIDs[previousKey]) {
Onyx_1.default.disconnect(this.activeConnectionIDs[previousKey], previousKey);
delete this.activeConnectionIDs[previousKey];
this.connectMappingToOnyx(mapping, propName, newKey);
} |
@miljakljajic, @shubham1206agra Whoops! This issue is 2 days overdue. Let's get this updated quick! |
reviewing proposals still |
@miljakljajic I am waiting for a better proposal. The current proposals add listeners to all reports, which I think is not a good approach. |
@shubham1206agra The data the page gets from the route is accountID and it needs to get the DM report linked to that participant and if reports data is not ready we will definitely need to recalculate the |
Can you give me a test branch for this? |
Will do shortly |
@shubham1206agra Do you have any feedback about my proposal? |
I think I have same feedback as #35654 (comment). I just don't need to necessarily listen to all reports after initial rendering. |
Here it is @shubham1206agra |
@shubham1206agra I updated my alternative solution based on the RCA |
@shubham1206agra be notified that made changes on the test branch 👍 |
@FitseTLT I still don't like this solution. @dukenv0307 We cannot update the Onyx logic. Maybe design a selector for all reports (Not sure if it prevents re-rendering on any change in the collection). |
Can you give me more details about this one? The current behavior is that the report key here has correct key but the Onyx does not listen to that case |
Maybe see the SidebarLinkData component. |
@shubham1206agra yep. We just need to get all the properties that will be used in getChatByParticipants |
Sure! Awaiting the regression period to run down melv, chill. |
^ Same |
👋 Checklist time please! |
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:
|
@trjExpensify Can you process payment here, please? |
Yep! Payment summary as follows:
@dukenv0307 I've paid you. @shubham1206agra doesn't look like you've accepted the offer yet. |
@trjExpensify Can you hold my payment temporarily as per https://expensify.slack.com/archives/C02NK2DQWUX/p1710150138788529? |
Yep, please comment here when your ready. Dropping to |
@trjExpensify I have discussed this internally. You may close this issue as I am keeping track of payment internally and will ask to pay once the issue is resolved. Just write in the payment summary that I have not been paid yet. |
Sounds good, closing! |
@trjExpensify We can process payment here now. |
Sent a new offer. |
Accepted |
Paid! |
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: 1.4.35-0
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:
Precondition:
User A have a existing conversation with User B
Expected Result:
Since there is a existing conversation between users - on the Profile modal Private notes should be present
Actual Result:
Private notes does not appear on existing conversation when navigate logged out via Share code link
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Bug6364618_1706866486295.az_recorder_20240201_222649.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @shubham1206agraThe text was updated successfully, but these errors were encountered: