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

[HOLD for payment 2025-02-05] [HOLD for payment 2025-02-04] [mWeb iOS / Safari 17.2] - PDF attachment doesn't load (endless spinner) #55176

Open
1 of 8 tasks
m-natarajan opened this issue Jan 13, 2025 · 33 comments
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Needs Reproduction Reproducible steps needed Weekly KSv2

Comments

@m-natarajan
Copy link

m-natarajan commented Jan 13, 2025

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Version Number:
Reproducible in staging?: needs reproduction
Reproducible in production?: needs reproduction
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?:
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: @jjcoffee
Slack conversation (hyperlinked to channel name): Expensify-bugs

Action Performed:

  1. Add any PDF attachment to a chat.
  2. Open the attachment.

Expected Result:

Attachment displays.

Actual Result:

Attachment doesn't load, the spinner spins endlessly.

Workaround:

unknown

Platforms:

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

  • Android: Standalone
  • Android: HybridApp
  • Android: mWeb Chrome
  • iOS: Standalone
  • iOS: HybridApp
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence
ios-safari-2025-01-13_15.37.01.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @VictoriaExpensify
@m-natarajan m-natarajan added Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 Needs Reproduction Reproducible steps needed labels Jan 13, 2025
Copy link

melvin-bot bot commented Jan 13, 2025

Triggered auto assignment to @VictoriaExpensify (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.

@MelvinBot
Copy link

This has been labelled "Needs Reproduction". Follow the steps here: https://stackoverflowteams.com/c/expensify/questions/16989

@rezkiy37
Copy link
Contributor

Hi, I am Michael (Mykhailo) from Callstack, an expert agency and I can work on this issue.

@jjcoffee
Copy link
Contributor

I can reproduce (I am the bug reporter), please assign me @VictoriaExpensify.

ios-safari-2025-01-13_15.37.01.mp4

@rezkiy37
Copy link
Contributor

Working on the issue.

@rezkiy37
Copy link
Contributor

I just found one more bug related to Expensify/react-fast-pdf#30. The problem is replicable on the latest package version. However, I can see that the package version in the example is pretty old - 1.0.2 while the current is 1.0.21. I am going to upgrade the package version and fix the bug. Basically, it conflicts with styles.

Bug.mp4

@rezkiy37
Copy link
Contributor

After investigations, I've found only one combination that works with IOS 17.x. It is the legacy PDF worker. Moreover, it must be unminimized - pdfjs-dist/legacy/build/pdf.worker.mjs.

pdfjs-dist/legacy/build/pdf.worker.mjs.

Image

pdfjs-dist/legacy/build/pdf.worker.min.mjs.

Image

@rezkiy37
Copy link
Contributor

No overdue. I am actively working on the issue.

@jjcoffee
Copy link
Contributor

I think @VictoriaExpensify might need to comment in order to remove the overdue label. Please assign me while you're at it 😄

@rezkiy37
Copy link
Contributor

I just opened Expensify/react-fast-pdf#43 for review.

@rezkiy37
Copy link
Contributor

To do:

  1. Investigate if possible to apply the latest PDF.js worker for newer features and optimization.
  2. Fix the example [HOLD for payment 2025-02-05] [HOLD for payment 2025-02-04] [mWeb iOS / Safari 17.2] - PDF attachment doesn't load (endless spinner) #55176 (comment).
  3. Upgrade react-fast-pdf version in the example.
  4. Upgrade react-fast-pdf version in the Expensify app.

@rezkiy37
Copy link
Contributor

I just opened Expensify/react-fast-pdf#42 for review.

@rezkiy37
Copy link
Contributor

The PRs in review.

@rezkiy37
Copy link
Contributor

Can we add a reviewing label?

@mountiny mountiny added the Reviewing Has a PR in review label Jan 17, 2025
@rezkiy37 rezkiy37 mentioned this issue Jan 17, 2025
50 tasks
@rezkiy37
Copy link
Contributor

I just opened #55421 for review.

@melvin-bot melvin-bot bot removed the Daily KSv2 label Jan 17, 2025
@melvin-bot melvin-bot bot added the Weekly KSv2 label Jan 17, 2025
@rezkiy37
Copy link
Contributor

I just found the official doc and a link to test by Mozilla. It can confirm that IOS Safari 17.x supports only the legacy worker.

Details

https://github.com/mozilla/pdf.js?tab=readme-ov-file#online-demo

Image Image

@rezkiy37
Copy link
Contributor

I am working on some dynamic solutions to apply the correct worker for the latest browsers and the legacy for the older ones.

@rezkiy37
Copy link
Contributor

rezkiy37 commented Jan 21, 2025

I have an idea:

  1. Import both workers.
  2. Get IOS version.
  3. If <18 - legacy; if >=18 - modern.

Testing it.

@rezkiy37
Copy link
Contributor

Working on the idea above. The project is not stable yet with this change.

@rezkiy37
Copy link
Contributor

Other tasks have occupied me today.

@rezkiy37
Copy link
Contributor

@tgolen has found one regression. I am working on the fix.

#55421 (comment), #55421 (comment)

@rezkiy37
Copy link
Contributor

Just opened for review #55743.

@rezkiy37
Copy link
Contributor

Other tasks have occupied me today. I am working on the issue tomorrow.

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Weekly KSv2 labels Jan 28, 2025
@melvin-bot melvin-bot bot changed the title [mWeb iOS / Safari 17.2] - PDF attachment doesn't load (endless spinner) [HOLD for payment 2025-02-04] [mWeb iOS / Safari 17.2] - PDF attachment doesn't load (endless spinner) Jan 28, 2025
Copy link

melvin-bot bot commented Jan 28, 2025

Reviewing label has been removed, please complete the "BugZero Checklist".

@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label Jan 28, 2025
Copy link

melvin-bot bot commented Jan 28, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.89-8 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 2025-02-04. 🎊

For reference, here are some details about the assignees on this issue:

  • @jjcoffee requires payment through NewDot Manual Requests
  • @rezkiy37 does not require payment (Contractor)
  • @jjcoffee requires payment through NewDot Manual Requests

Copy link

melvin-bot bot commented Jan 28, 2025

@jjcoffee @VictoriaExpensify @jjcoffee The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

@rezkiy37
Copy link
Contributor

I still have some tasks to work on. The issue in not completed yet.

@rezkiy37
Copy link
Contributor

rezkiy37 commented Jan 28, 2025

Just opened for review Expensify/react-fast-pdf#44.

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels Jan 29, 2025
@melvin-bot melvin-bot bot changed the title [HOLD for payment 2025-02-04] [mWeb iOS / Safari 17.2] - PDF attachment doesn't load (endless spinner) [HOLD for payment 2025-02-05] [HOLD for payment 2025-02-04] [mWeb iOS / Safari 17.2] - PDF attachment doesn't load (endless spinner) Jan 29, 2025
Copy link

melvin-bot bot commented Jan 29, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.0.90-6 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 2025-02-05. 🎊

For reference, here are some details about the assignees on this issue:

  • @jjcoffee requires payment through NewDot Manual Requests
  • @rezkiy37 does not require payment (Contractor)
  • @jjcoffee requires payment through NewDot Manual Requests

Copy link

melvin-bot bot commented Jan 29, 2025

@jjcoffee @VictoriaExpensify @jjcoffee The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

@rezkiy37
Copy link
Contributor

I still have some tasks to work on. The issue in not completed yet.

@rezkiy37
Copy link
Contributor

Other tasks have occupied me today. I am working on the issue tomorrow.

@rezkiy37
Copy link
Contributor

Testing it today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Needs Reproduction Reproducible steps needed Weekly KSv2
Projects
None yet
Development

No branches or pull requests

6 participants