-
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-08-21] [$1000] Multiline codeblocks disappear after editing twice #18928
Comments
Triggered auto assignment to @laurenreidexpensify ( |
Bug0 Triage Checklist (Main S/O)
|
Closing as not reproducible |
Hi @laurenreidexpensify, the issue is when we edit the codeblock again. |
Not able to login on web staging but made a video using mobile chrome, was able to reacreate in first edit if kept the first character and last character or word besides the 3 backticks. The video is over 10 mb so will post it on slack in the report thread |
Reopening to review and see if still reproducible as per feedback from @dhanashree-sawant |
Job added to Upwork: https://www.upwork.com/jobs/~01bba6b459f7297429 |
Current assignee @laurenreidexpensify is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @Santhosh-Sellavel ( |
Managed to reproduce, sending to upwork |
Triggered auto assignment to @puneetlath ( |
ProposalPlease re-state the problem that we are trying to solve in this issue.Multiline codeblocks disappear after editing twice. What is the root cause of that problem?Adding a comment
is translated into html <pre>1<br />2</pre> The html above is translated into markdown
when click edit the comment. If edit the comment into
then in method editReportComment
<pre>1<br />2</pre>
<pre>1<br />2<br /></pre> after doing App/src/libs/actions/Report.js Line 935 in 98ae1ae
So, the condition App/src/libs/actions/Report.js Line 945 in 98ae1ae
return false and we save the same html to the backend. Note that the backend will return empty message which make the comment disappear So the root cause is that What changes do you think we should make in order to solve the problem?We can add an alternative condition to skip saving the html to backend, like if (parsedOriginalCommentHTML === htmlForNewComment.trim() || originalCommentHTML === htmlForNewComment.trim()) {
return;
} What alternative solutions did you explore? (Optional)N/A |
Contributor details ProposalPlease re-state the problem that we are trying to solve in this issue.Multiline codeblocks disappear after editing twice. What is the root cause of that problem?Regarding the add a comment When you edit the comment like the bellow
But <pre>1<br />2<br /></pre> As a result, this condition returning false value App/src/libs/actions/Report.js Line 945 in 98ae1ae
That's why the backend will return empty value for the But when we switch to other tabs and back to this tab, it corrects with What changes do you think we should make in order to solve the problem?Remove outdated code snippet about the conversions of App/src/libs/actions/Report.js Lines 933 to 936 in 98ae1ae
Then we won't save the same html to the backend. What alternative solutions did you explore? (Optional)N/A |
📣 @blockchainGuru1018! 📣
|
@puneetlath @laurenreidexpensify @Santhosh-Sellavel this issue is now 3 weeks old. There is one more week left before this issue breaks WAQ and will need to go internal. What needs to happen to get a PR in review this week? Please create a thread in #expensify-open-source to discuss. Thanks! |
Cool, sounds good to me. @eh2077 let's make sure we add some automated tests for the various scenarios related to this. |
@abdulrahuman5196 thank you for the review. I created my proposal but before proposing it I wanted to make sure that my solution isn't redundant. Our solutions with @eh2077 are really similar so I decided to propose these changes to @eh2077's idea. So yes, it was cooperation :D |
@abdulrahuman5196 I updated the solution to proposal. I also found the bug is a slight different from the bug report now. The edited comment doesn’t disappear but it'll return to unchanged after switching tab. 18928-dup.movThe difference is that the backend now returns empty So the App/src/libs/actions/Report.js Line 1074 in 5775b4f
I think our solution is still applicable to fix the bug. |
Yes, I fixed the back-end response so that it wouldn't disappear. But I agree, we can still fix the front-end so that it isn't considered to be "edited" and the API doesn't even get called in this scenario. |
Gentle bump @abdulrahuman5196. The PR #24205 is ready for review, thanks! |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.53-2 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-08-21. 🎊 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:
As a reminder, here are the bonuses/penalties that should be applied for any External 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:
|
Payment Summary:
|
@laurenreidexpensify Can you kindly send me the offer in Upwork? |
Hi @laurenreidexpensify, I think offer sending for this job is left, I too don't have any offer. Can you check once? |
Folks - massive apologies, I don't know why I thought this had been accepted by everyone last week!! I have sent offers to everyone in Upwork now for job https://www.upwork.com/en-gb/jobs/~0189f147050f87dc01, as the original job here expired. Thanks |
@laurenreidexpensify Accepted the offer, thank you! |
Everyone has been paid in Upwork - @abdulrahuman5196 can you please complete the checklist, thanks |
Not a regression. Seems to be present for sometime.
No. Minor edge. Regression test won't be required. |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
Expected Result:
Codeblock should not disappear on edit
Actual Result:
Codeblock disappears on edit in mac chrome/mac safari
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.3.13.3
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
Notes/Photos/Videos: Any additional supporting documentation
2023-05-13.08-54-46.mp4
Recording.616.mp4
Expensify/Expensify Issue URL:
Issue reported by: @dhanashree-sawant
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1683890048581339
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: