Skip to content
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

[Ready for Payment][$250] Android - Chat - On sending attachment+text, on edit url is not shown as hyperlink #46491

Closed
1 of 6 tasks
lanitochka17 opened this issue Jul 30, 2024 · 33 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review Weekly KSv2

Comments

@lanitochka17
Copy link

lanitochka17 commented Jul 30, 2024

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: 9.0.14
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/4787789
Email or phone of affected tester (no customers): N/A
Issue reported by: Applause - Internal Team

Action Performed:

  1. Launch app
  2. Tap on a report
  3. Enter a url + upload a image and send the message
  4. Long press and edit the message sent
  5. Enter a url and email id along with previous url entered and save the message

Expected Result:

On sending attachment+text, on edit url must be shown as hyperlink

Actual Result:

On sending attachment+text, on edit url is not shown as hyperlink

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6556677_1722285950066.Screenrecorder-2024-07-30-02-04-50-96_compress_1.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01a793178e3d46661b
  • Upwork Job ID: 1821194033275560441
  • Last Price Increase: 2024-08-07
Issue OwnerCurrent Issue Owner: @JmillsExpensify
@lanitochka17 lanitochka17 added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Jul 30, 2024
Copy link

melvin-bot bot commented Jul 30, 2024

Triggered auto assignment to @JmillsExpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

@lanitochka17
Copy link
Author

We think that this bug might be related to #vip-vsp

@lanitochka17
Copy link
Author

@JmillsExpensify FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors

@bernhardoj
Copy link
Contributor

Proposal

Please re-state the problem that we are trying to solve in this issue.

Adding a link before the image markdown doesn't convert the link, example:

google.com
![alt](source.com)

What is the root cause of that problem?

This issue comes from the ExpensiMark autolink markdown regex. The regex doesn't allow a self-closing tag after the link. The image markdown is converted to <img ... /> which is a self-closing tag, so the link is never matched.

It was updated to solve this issue.

What changes do you think we should make in order to solve the problem?

The issue that the self-closing tag regex is trying to solve looks like doesn't even happen anymore, so we can remove the self-closing tag regex .+\\/> from the autolink regex.

@melvin-bot melvin-bot bot added the Overdue label Aug 1, 2024
Copy link

melvin-bot bot commented Aug 2, 2024

@JmillsExpensify Whoops! This issue is 2 days overdue. Let's get this updated quick!

Copy link

melvin-bot bot commented Aug 6, 2024

@JmillsExpensify 6 days overdue. This is scarier than being forced to listen to Vogon poetry!

@JmillsExpensify
Copy link

I'll open up this issue for proposal review since we have one already. If it's an easy fix we can address it. Otherwise, I think we should close the issue.

@melvin-bot melvin-bot bot removed the Overdue label Aug 7, 2024
@JmillsExpensify JmillsExpensify added the External Added to denote the issue can be worked on by a contributor label Aug 7, 2024
Copy link

melvin-bot bot commented Aug 7, 2024

Job added to Upwork: https://www.upwork.com/jobs/~01a793178e3d46661b

@melvin-bot melvin-bot bot changed the title Android - Chat - On sending attachment+text, on edit url is not shown as hyperlink [$250] Android - Chat - On sending attachment+text, on edit url is not shown as hyperlink Aug 7, 2024
@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 7, 2024
Copy link

melvin-bot bot commented Aug 7, 2024

Triggered auto assignment to Contributor-plus team member for initial proposal review - @getusha (External)

@getusha
Copy link
Contributor

getusha commented Aug 9, 2024

@bernhardoj I don't see any issues after applying the change too.
But i noticed it's not adding the text before the link as alt attribute of the image

Screenshot 2024-08-09 at 5 13 06 at night

@getusha
Copy link
Contributor

getusha commented Aug 9, 2024

Same issue on staging, do you think it's a bug and simple enough to handle it here?

@bernhardoj
Copy link
Contributor

I can repro that and the img tag itself has the alt attribute,
Screenshot 2024-08-09 at 10 21 32

but our ImageRenderer never uses that (not sure why). We can fix it by passing the alt as accessibilityLabel to the image.

@getusha
Copy link
Contributor

getusha commented Aug 11, 2024

@bernhardoj the solution is working fine, but it's not highlighting the link in the composer if it's placed before the image.

Screenshot 2024-08-11 at 1 21 20 in the afternoon

@bernhardoj
Copy link
Contributor

@getusha we would need to update the live markdown to use the new update from expensify-common. You can test it locally by updating node_modules/@expensify/react-native-live-markdown/lib/parser/react-native-live-markdown-parser.js and search for the "autolink" rule.

image

Copy link

melvin-bot bot commented Aug 13, 2024

@JmillsExpensify @getusha this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

@melvin-bot melvin-bot bot added the Overdue label Aug 13, 2024
@getusha
Copy link
Contributor

getusha commented Aug 14, 2024

@bernhardoj's proposal looks good to me.
🎀 👀 🎀 C+ Reviewed!

Copy link

melvin-bot bot commented Aug 14, 2024

Triggered auto assignment to @dangrous, see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@dangrous
Copy link
Contributor

ah okay cool - if we don't have that bug anymore I'm fine with this fix. To double check, though, we should include testing steps for that issue as well as the issue raised here. Assigning!

@melvin-bot melvin-bot bot removed the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 14, 2024
@bernhardoj
Copy link
Contributor

expensify-common PR is ready

cc: @getusha

Copy link

melvin-bot bot commented Aug 19, 2024

@JmillsExpensify, @dangrous, @bernhardoj, @getusha Eep! 4 days overdue now. Issues have feelings too...

@melvin-bot melvin-bot bot added the Overdue label Aug 19, 2024
@dangrous
Copy link
Contributor

Not overdue, Expensify/expensify-common#782 was just merged. I think we need an additional app PR to bump the version to 2.0.76 right?

@bernhardoj
Copy link
Contributor

bernhardoj commented Aug 20, 2024

@dangrous We need to bump the version in live markdown first. I have opened the live markdown PR here

cc: @getusha

@dangrous
Copy link
Contributor

ah great, I'll take a look at that shortly and merge

@melvin-bot melvin-bot bot added Reviewing Has a PR in review Weekly KSv2 and removed Daily KSv2 labels Aug 21, 2024
@bernhardoj
Copy link
Contributor

The App PR is ready

cc: @getusha

@dangrous
Copy link
Contributor

dangrous commented Sep 4, 2024

This looks like it was affected by the missing automation on prod deploy. I think we're in the 7 day waiting period @JmillsExpensify? But not sure when it started.

@dangrous
Copy link
Contributor

dangrous commented Sep 9, 2024

I'm pretty sure this one has completed the 7-day regression period, but not 100%. @JmillsExpensify do you know if there's an easy way to confirm? There was discussion about this somewhere...

@dangrous dangrous changed the title [$250] Android - Chat - On sending attachment+text, on edit url is not shown as hyperlink [Ready for Payment][$250] Android - Chat - On sending attachment+text, on edit url is not shown as hyperlink Sep 12, 2024
@dangrous
Copy link
Contributor

Now this is definitely ready to go.

@bernhardoj
Copy link
Contributor

Requested in ND.

@garrettmknight
Copy link
Contributor

Payment Summary:

@JmillsExpensify
Copy link

$250 approved for @bernhardoj

@JmillsExpensify
Copy link

@getusha do you mind filling out the BZ checklist?

@getusha
Copy link
Contributor

getusha commented Sep 29, 2024

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:

[@] The PR that introduced the bug has been identified. Link to the PR: Expensify/expensify-common#661
[@] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment: N/a
[@] A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion: N/a
[@] Determine if we should create a regression test for this bug. No, i don't think this issue is impactful. it's more like an edge case.
[@] If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again. N/a

@garrettmknight
Copy link
Contributor

$250 approved for @getusha

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Reviewing Has a PR in review Weekly KSv2
Projects
None yet
Development

No branches or pull requests

6 participants