DevTools: capture full page screenshot renders blank page |
||||||||||
Issue description- Start Chrome on MacOS - Go to https://developers.google.com/web/tools/chrome-devtools/ - Open DevTools - Hit Cmd+Shift+P, type "full" - Choose the "Capture full size streenshot" Expected: 4Mb+ PNG with full page content Actual: 500Kb PNG that is blank Bisect range: https://chromium.googlesource.com/chromium/src/+log/1e290a054df71ea6df7aa8f870f85e84a0540935..5157f928d980f7913d23144c597438d4c4f65699 Suspected CL: https://chromium.googlesource.com/chromium/src/+/e544a1ed8f62f4416060033ee0ff2ca0050af896
,
Apr 11 2018
,
Apr 11 2018
It is unrealistic to fix this issue in 24 hour (the stable branch cut date is tomorrow). My fix may introduce new bugs as well. If this bug is just reported after living in dev channel for so long, it may not be a release blocker bug.
,
Apr 12 2018
It also happens with windows and linux. I found the following: 1. it's kinda broken without my patch. It doesn't do a full screen capture.... it's cut at the end. 2. The bug is not in the CopyReuqest. The crash is due to "dimensions out of range". Because the TextureManager::ValidForTarget returns false. As the total height passed the maximum size. I also tried the take screenshot of wikipedia of different length, all pages with height less than maximum height works. the Maximum height allowed is 0x4000, or 16384. I need to understand why we have this height request, and how to update the height.
,
Apr 12 2018
3. If chrome is run with --disable-gpu, then this capture full page works.
,
Apr 12 2018
Thank you for the investigation. Do you know what change triggered the failure? We used to cap at 0x4000 and that was a known limitation. Also, Chrome Mac Stable (65.0.3325.181) produces the full size screenshot of theverge.com with 1740 × 19970 pixels dimensions for me - the 0x4000 limit does not seem to apply there, a bug? Probably due to the device scale factor being 2.
,
Apr 12 2018
The maximum texture size is driver/hardware dependent, only the minimum of 2048 is guaranteed. See https://www.khronos.org/registry/OpenGL-Refpages/es3.0/html/glGet.xhtml under GL_MAX_TEXTURE_SIZE This is what TextureManager::ValidForTarget checks for. We don't really have (never had) a facility to take a copy via multiple textures (which would really have to mean, composite multiple times). Clamping to the max texture size is probably the best workaround here, we probably were doing that in the old path and not the new one?
,
Apr 12 2018
I tried to take a full size screenshot of theverge.com on linux with stable channel. it's still cut for me.
,
Apr 12 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b0634a799e9fb68487132d97b9fae7531492a491 commit b0634a799e9fb68487132d97b9fae7531492a491 Author: Pavel Feldman <pfeldman@chromium.org> Date: Thu Apr 12 18:00:39 2018 DevTools: capture full page screenshot renders blank page for pages higher than 0x4000px. Bug: 831773 Change-Id: Ia5dfad17af526b495c38d6827292364a1d505dba TBR: dgozman Reviewed-on: https://chromium-review.googlesource.com/1010476 Commit-Queue: Pavel Feldman <pfeldman@chromium.org> Reviewed-by: Pavel Feldman <pfeldman@chromium.org> Reviewed-by: Dmitry Gozman <dgozman@chromium.org> Cr-Commit-Position: refs/heads/master@{#550264} [modify] https://crrev.com/b0634a799e9fb68487132d97b9fae7531492a491/third_party/blink/renderer/devtools/front_end/emulation/DeviceModeModel.js
,
Apr 12 2018
I'm aware of the 16K limitation, I already landed the cap on the client side that I intend to merge everywhere (https://chromium-review.googlesource.com/c/chromium/src/+/1010476). But a couple of things are mysterious to me: - As I mention in comment #6, Mac is capable of capturing higher screenshots, probably due to the difference in the device scale as I mention in the same comment. I wonder why... - I don't think --disable-gpu works around it. We've observed similar capture cap in headless chrome that has no gpu.
,
Apr 12 2018
I tried your patch, it worked!@!!!!!! Thank you so much for helping out!!!! I don't know this part of the chrome at all! Do you want me to merge to the stable branch or you will do it?
,
Apr 13 2018
Tried checking the issue on latest canary 67.0.3396.0 and on 67.0.3393.0(Assuming this version with issue i.e., without fix) using Mac 10.13.1 with the below mentioned steps. 1. Launched Chrome 2. Navigated to https://developers.google.com/web/tools/chrome-devtools/ 3. Hit Cmd+Shift+P and typed "full" 4. Have Chosen the "Capture full size screenshot" We are able to see the images captured in both the above mentioned versions are same i.e., 3.6MB. Attaching the captured images for reference. @Pavel Feldman: Could you please have a look at the screen shots provided and please help us in verifying the fix. Thanks!
,
Apr 13 2018
How safe is this fix overall? And how widely does this impact developers? My preference is to wait until M67, however if this is critical and a safe fix, then we should consider a merge to 66.
,
Apr 15 2018
@pdeldman: could you provide some feedback to comment 13? I personally feel that it's safe to merge to m66.
,
Apr 15 2018
Issue 812518 has been merged into this issue.
,
Apr 16 2018
+Dmitry Gozman for feedbacks
,
Apr 16 2018
abdulsyed@: it is very safe, how are we looking with the timeline though? It is not worth merging into stable, but if we are still facing another beta, we should do it.
,
Apr 16 2018
We have stable tomorrow. My recommendation is to punt it to 67.
,
Apr 17 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/b0634a799e9fb68487132d97b9fae7531492a491 commit b0634a799e9fb68487132d97b9fae7531492a491 Author: Pavel Feldman <pfeldman@chromium.org> Date: Thu Apr 12 18:00:39 2018 DevTools: capture full page screenshot renders blank page for pages higher than 0x4000px. Bug: 831773 Change-Id: Ia5dfad17af526b495c38d6827292364a1d505dba TBR: dgozman Reviewed-on: https://chromium-review.googlesource.com/1010476 Commit-Queue: Pavel Feldman <pfeldman@chromium.org> Reviewed-by: Pavel Feldman <pfeldman@chromium.org> Reviewed-by: Dmitry Gozman <dgozman@chromium.org> Cr-Commit-Position: refs/heads/master@{#550264} [modify] https://crrev.com/b0634a799e9fb68487132d97b9fae7531492a491/third_party/blink/renderer/devtools/front_end/emulation/DeviceModeModel.js
,
Apr 18 2018
I’ve received a dozen reports of this issue from people using my screenshotting extension, which means it’s probably happening to a much larger # of people. Do you have any suggestions on what can I tell them other than to wait ~1.5 months?
,
Apr 19 2018
Has this fix been verified in Dev? Which branch is this merged in?
,
Apr 23 2018
it's verified in comment 12 i believe. It's merged in to 67.0.3396.0.
,
Apr 25 2018
,
Apr 25 2018
,
Jun 11 2018
I just received a report of this still happening to someone who is running Chrome 67.0.3396 on Mac OS X 10.11.6. They verified that running Chrome as `/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --disable-gpu` was able to successfully capture a screenshot.
,
Jun 21 2018
@peter: Could you please create a new bug with details on the users' hardware specifications? Thank you. |
||||||||||
►
Sign in to add a comment |
||||||||||
Comment 1 by pfeldman@chromium.org
, Apr 11 2018