-
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-07-06] [$1000] Welcome message of custom workspace room translates HTML code to character in offline mode (works fine in online mode) #20783
Comments
Triggered auto assignment to @lschurr ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.Welcome message of custom workspace room translates HTML code to character in offline mode (works fine in online mode) What is the root cause of that problem?In offline mode App/src/libs/actions/Report.js Line 1106 in 862955c
and then in ReportWelcomeMessagePage , it is converted to character by parser.htmlToMarkdown(props.report.welcomeMessage) App/src/pages/ReportWelcomeMessagePage.js Line 38 in 862955c
While we pass welcomeMessage in the payload of API is parsedWelcomeMessage and after API return data props.report.welcomeMessage now is updated to parsedWelcomeMessage so that this issue doesn't occur in online modeApp/src/libs/actions/Report.js Line 1116 in 862955c
What changes do you think we should make in order to solve the problem?We should update What alternative solutions did you explore? (Optional) |
Job added to Upwork: https://www.upwork.com/jobs/~01187aec34f1d4c1eb |
Current assignee @lschurr is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @0xmiroslav ( |
Triggered auto assignment to @techievivek ( |
I think this could be related to this other issue when using HTML character codes in the workspace name. |
ProposalPlease re-state the problem that we are trying to solve in this issue.Welcome message of workspace room translates HTML code to character in offline mode(It works fine in online mode) What is the root cause of that problem?The What changes do you think we should make in order to solve the problem?
const replacedElement = this.replaceBlockElementWithNewLine(generatedMarkdown)
const decodedHtml = Str.htmlDecode(replacedElement)
if (decodedHtml && decodedHtml !== '0') return decodedHtml;
return replacedElement; The original codebase is return Str.htmlDecode(this.replaceBlockElementWithNewLine(generatedMarkdown)); What alternative solutions did you explore? (Optional)If this expensify common lib should not be changed, the changes should be in setting the initial value of const parsedMarkdown = parser.htmlToMarkdown(props.report.welcomeMessage)
const [welcomeMessage, setWelcomeMessage] = useState(parsedMarkdown && parsedMarkdown !== 0 ? parsedMarkdown : props.report.welcomeMessage); |
📣 @univalchemist! 📣
|
Contributor details |
✅ Contributor details stored successfully. Thank you for contributing to Expensify! |
Added video in proposal |
Bumping @0xmiroslav to have a look at the above proposals. |
Hi @0xmiroslav - looks like we're still waiting for your review. |
I am inclined to @dukenv0307's root cause and solution. |
@dukenv0307's proposal looks good to me. |
Triggered auto assignment to @Beamanator, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
@techievivek I'm unassigning myself b/c you were assigned here first (I think i got assigned because of the new process - C+ approving proposals) |
📣 @dukenv0307 You have been assigned to this job by @techievivek! |
@0xmiroslav Hi, The PR is ready for review |
🎯 ⚡️ Woah @0xmiroslav / @dukenv0307, great job pushing this forwards! ⚡️ The pull request got merged within 3 working days of assignment, so this job is eligible for a 50% #urgency bonus 🎉
On to the next one 🚀 |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.34-1 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-07-06. 🎊 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.
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:
|
@dukenv0307 @0xmiroslav - could you apply for the job in Upwork? https://www.upwork.com/jobs/~01187aec34f1d4c1eb |
Also @0xmiroslav do we need a regression test for this one? |
@dhanashree-sawant could you also apply for the job in Upwork for the reporting bonus? |
I don't think regression test is needed. This issue itself is edge case. |
Thanks @lschurr, if possible, can you invite me to the job? |
@dhanashree-sawant could you include your Upwork profile here so that I can invite you to the job? |
Hi @lschurr, Thanks. |
All paid and closed :) |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Action Performed:
Expected Result:
App should not convert HTML code to HTML character in room welcome message
Actual Result:
In offline mode, app converts HTML code to HTML character in room welcome message
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.2.27.6
Reproducible in staging?: yes
Reproducible in production?: n/a
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
app.converts.html.code.to.character.welcome.message.1.mp4
Recording.722.1.mp4
Expensify/Expensify Issue URL:
Issue reported by: @dhanashree-sawant
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1686214026251619
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: