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

Some PDFs don't open #1033

Closed
stshank opened this issue Sep 8, 2018 · 21 comments · Fixed by brave/brave-core#967
Closed

Some PDFs don't open #1033

stshank opened this issue Sep 8, 2018 · 21 comments · Fixed by brave/brave-core#967

Comments

@stshank
Copy link

stshank commented Sep 8, 2018

Description

Some PDFs don't open

Steps to Reproduce

  1. go to https://spark.att.com/5g-white-papers
  2. Click "white papers in upper right
  3. Click "download" buttons

Actual result:

PDF won't display
Error message:
PDF.js v2.0.673 (build: 31012570)
Message: Failed to fetch

Expected result:

PDF displays

Reproduces how often:

always

Brave version (about:brave info)

Version 0.55.1 Chromium: 70.0.3528.4 (Official Build) dev (64-bit)
MacOS Mojave beta 10

Reproducible on current release:

Unknown

Website problems only:

  • Does the issue resolve itself when disabling Brave Shields?
    No
  • Is the issue reproducible on the latest version of Chrome?
    No
@prakaashkpk
Copy link

I am able to open the PDF.js in my mac. but I am using pdf.js version bundled with my browser.

Brave: 0.23.105 
PDF Viewer 1.9.459
OS Release: 17.7.0 

@srirambv srirambv added this to the 1.x Backlog milestone Sep 8, 2018
@hugobuddel
Copy link

Another one via brave/browser-laptop#14674 (comment)

chrome-extension://oemmndcbldboiebfnladdacbdfmadadm/https://onlinelibrary.wiley.com/doi/pdf/10.1111/cdev.12853

It is especially annoying with pdf's that require login, because those can't be wget-ed either.

@oxfordia
Copy link

oxfordia commented Nov 4, 2018

www.chase.com >> cannot open my monthly statements ("open as pdf") (CAN login and browse site)
www.ebay.com >> cannot open pdf of labels necessary to ship

CHASE.com ERROR:
PDF.js v2.0.673 (build: 31012570)
Message: Unexpected server response (401) while retrieving PDF "https://secure07a.chase.com/svc/rr/documents/secure/idal/v2/pdfdoc/star/list?docKey=c1f3b968-a0a3-4ffc-8581-59d290f89c4c&adaVersion=false&csrftoken=de8d4ad837215be586daa889dad7110098e4c9d45f7e971b74991f37bb6d5f64&download=false&fromOrigin=https%253A%252F%252Fsecure07a.chase.com".

Brave is up to date
Version 0.55.22 Chromium: 70.0.3538.77 (Official Build) (64-bit)

Does not matter if shields are up or down

@rebron rebron added the priority/P2 A bad problem. We might uplift this to the next planned release. label Nov 13, 2018
@MJae
Copy link

MJae commented Nov 14, 2018

Just encountered the same in Version 0.55.22 Chromium: 70.0.3538.77 (Official Build) (64-bit) while trying to download a certificate from OpenLearn: "Invalid or corrupted PDF file."

Clicking on "More information" gives me this:

PDF.js v2.0.673 (build: 31012570)
Message: Invalid PDF structure

Download link worked without issue in Firefox Nightly 65.0a1.

@srirambv
Copy link
Contributor

+1 from @avndp via #2135

@shriram
Copy link

shriram commented Nov 25, 2018

Still having this problem on 0.56.15 on numerous sites, some of them work-critical.
PDF.js v2.0.673 (build: 31012570) [same as reported by @MJae above]
Same pages work just fine with Chrome.
macOS Mojave 10.14.1 (18B2107)

@jonathansampson
Copy link
Contributor

@shriram Thank you for the feedback. If you have a couple URLs that can be shared, that would be helpful. I suspect there may be a couple scenarios represented here, and more data will certainly help to ensure all issues are addressed.

@shriram
Copy link

shriram commented Nov 25, 2018 via email

@jonathansampson
Copy link
Contributor

Internet fetch fails due to no-cors. This results in a data: request, which isn't permitted.

@BrendanEich
Copy link
Member

@jonathansampson is no-cors our setting, or is the site using CSP?

@hugobuddel
Copy link

Just summarizing, since this is the main reason I have to use other browsers. Using Version 0.56.14 Chromium: 70.0.3538.102 (Official Build) unknown (64-bit)

Steps to Reproduce

  1. go to https://spark.att.com/5g-white-papers
  2. Click "white papers in upper right
  3. Click "download" buttons

This works properly now.

Another one via brave/browser-laptop#14674 (comment)

chrome-extension://oemmndcbldboiebfnladdacbdfmadadm/https://onlinelibrary.wiley.com/doi/pdf/10.1111/cdev.12853

This one seems to work properly as well.

It is especially annoying with pdf's that require login, because those can't be wget-ed either.

Perhaps this is one of the main scenario's that is still failing?

Right now all the ones I can think of were behind authentication barriers, and they represent confidential information.

Same for me. E.g. salary slips, so not possible to share/create an account. (I tried this several times on several computers / brave versions. Then I heard that some HR departments check how often people download their salary slip because this is an indication of employees wanting to leave 😅.)

But in the two most immediate cases I can think of — one a recommendation letter upload, the other a pay stub viewing — the PDF viewing was embedded in a Web page, rather than shown in a stand-alone page. [..] So, conjecture: the problem is when a page tries to embed a PDF viewer.

Nice observation. This might be the problem with my salary slips too.

@shriram
Copy link

shriram commented Nov 26, 2018

Agreed with @hugobuddel, this is the main reason I need another browser.

Unfortunately, his AT&T white paper example [https://developer.att.com/static-assets/documents/futurist-report/FuturistReport_5G-A-Faster-Smarter-Future_FINAL_083118.pdf] does not work for me in 0.56.15 [build 70.0.3538.110] (slightly newer version than in his report). The PDF.js error message is

PDF.js v2.0.673 (build: 31012570)
Message: Failed to fetch

Since the above is a .pdf URL, it unfortunately provides a counterexample to my proposition that this is an issue with embedded PDFs only. (I downloaded the file to see whether there was some clever embedding trick being played, but it appears not.)

@hugobuddel
Copy link

Can confirm that indeed that https://developer.att.com/static-assets/documents/futurist-report/FuturistReport_5G-A-Faster-Smarter-Future_FINAL_083118.pdf does not work. Also not on the version I reported working. I'm quite sure it worked this morning; must have been mistaken.

@bbondy
Copy link
Member

bbondy commented Nov 26, 2018

Thanks for your patience. Fix incoming.

@MJae
Copy link

MJae commented Nov 27, 2018

Just got updated to Version 0.56.15 Chromium: 70.0.3538.110

Tested example: https://developer.att.com/static-assets/documents/futurist-report/FuturistReport_5G-A-Faster-Smarter-Future_FINAL_083118.pdf

Confirmed still doesn't work with error:

PDF.js v2.0.673 (build: 31012570)
Message: Failed to fetch

@oxfordia
Copy link

I can also confirm STILL does NOT work.

WAITING PATIENTLY for "Fix incoming"

@bbondy
Copy link
Member

bbondy commented Nov 27, 2018

Fix is coded but not yet released. It's in the review phase right now. It'll likely get approved within a day or so, and merge to Dev channel 0.58.x which will go to beta channel on Dec 4th and Release channel on Dec 20th. So earlier access on Beta and Dev channel.

@bbondy
Copy link
Member

bbondy commented Nov 27, 2018

I'll try to get it uplifted to beta for release on ~Dec 4th.

@jsquyres
Copy link

Note that this issue seems to have regressed: in Brave 0.68.132, PDFs are downloading again instead of opening -- see #1264.

#1264 has sat in the "Untriaged / Incoming in Shields" project for quite a while. Can someone please have a look? Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment