-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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-09-06] [$2000] Web - The backtick is outside the code block when sending a message with two backticks #23352
Comments
Triggered auto assignment to @muttmuure ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.Using two backticks leads to an incorrect processing of a code block. What is the root cause of that problem?The regular expression that is used for recognizing code blocks uses 'lazy' matching, as opposed to 'greedy' matching which is required in this case. What changes do you think we should make in order to solve the problem?The last question mark inside Lastly, we could check for similar problems in the regular expressions of other markdown processing rules, such as the triple backtick block. What alternative solutions did you explore? (Optional)Option 1. Expand the regular expression to include an optional second backtick. regex: /(\B|_|)`(.*?\S.*?(`)*)`(\B|_|)(?![^<]*<\/pre>)/g,
replacement: '$1<code>$2</code>$4', Edit: Updated proposal |
@muttmuure Whoops! This issue is 2 days overdue. Let's get this updated quick! |
Asking about this here: https://expensify.slack.com/archives/C01GTK53T8Q/p1690384105813549 |
Job added to Upwork: https://www.upwork.com/jobs/~01f54ca2df0a387770 |
Current assignee @muttmuure is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @abdulrahuman5196 ( |
I think this issue can be fixed as follows:
|
📣 @manan-upadhyay! 📣
|
Contributor details |
✅ Contributor details stored successfully. Thank you for contributing to Expensify! |
This issue seems like a likely candidate to be added to the markdown tracking issue. A discussion was held in Slack about another issue involving backticks, and the consensus was it's better not to overcomplicate the code blocks' regular expressions for certain scenarios. I'd like to hear your thoughts on this one, @greg-schroeder, since you took part in the Slack discussion. |
Reviewing today |
ProposalPlease re-state the problem that we are trying to solve in this issue.text wrapped in two backticks is not parsed properly with code block, one backtick is out of code block. What is the root cause of that problem?in inline codeblock rule's regex pattern is using lazy mode to get code block content, so last backtick is not contained in code block content. What changes do you think we should make in order to solve the problem?to fix the root cause, add a tweak(adding a backtick option in negative lookahead) on inline codeblock's regex pattern
relevant test case is like below
it doesn't make other auto test cases failed, all passed. |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
Upwork job price has been updated to $2000 |
Thanks @Antasel! Taking a look |
Based on my calculations, the pull request did not get merged within 3 working days of assignment. Please, check out my computations here:
On to the next one 🚀 |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.58-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 2023-09-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.
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:
|
Not a regression. This issue is present from implementation.
No. We have already added Unit test cases to common package. |
@abdulrahuman5196 @muttmuure |
@jasperhuangg, @abdulrahuman5196, @muttmuure, @Antasel Whoops! This issue is 2 days overdue. Let's get this updated quick! |
@jasperhuangg, @abdulrahuman5196, @muttmuure, @Antasel Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
@jasperhuangg @muttmuure |
Catching up from OOO and looking today |
Reporter $250 - @daveSeife |
@muttmuure Thanks, Accepted offer |
@Antasel paid |
@daveSeife paid |
@abdulrahuman5196 paid |
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:
Backtick should be in the code block
Actual Result:
One Backtick is out of the code block
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.43-6
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
Test79_Backtick-1.mp4
Recording.3809.mp4
Expensify/Expensify Issue URL:
Issue reported by: @daveSeife
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1689891927706399
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: