Issue metadata
Sign in to add a comment
|
File drag&drop does now work from Drive |
||||||||||||||||||||||
Issue descriptionChrome Version : 56.0.2924.12 OS Version: 9000.15.0 What steps will reproduce the problem? 1. Open http://drive.google.com (or Dropbox or similar svc) for an account that isn't the one used to log in to Chrome OS. 2. Open Chrome OS Files.app, find a file on its Downloads section and try to drag it into tab from (1) 3. Open Files.app, find a file on its Drive section and try to drag it into tab from (1) What is the expected result? Both (2) and (3) should copy files into the file from Files.app to target website. What happens instead of that? (2) works, (3) doesn't. I believe this used to work in the past.
,
Dec 7 2016
Note that the snippet correctly loads data from dropped drive files. https://jsfiddle.net/5z34e89s/ We still need to check how Google Drive web interface loads data from dropped files.
,
Dec 7 2016
Tested on a simple internal site go/screenshots and it failed to upload.
,
Dec 7 2016
Bisecting...
,
Dec 7 2016
,
Dec 7 2016
,
Dec 7 2016
The issue does not happen R47-7520.67.0.
,
Dec 7 2016
The issue happens on R48.7647.84.0
,
Dec 8 2016
#8 was wrong. The issue started between R52-8350.74.0 and R53-8530.96.0. I'm building linux local build to proceed bisect. But linux chrome OS around that version consistently crashes when launching...
,
Dec 9 2016
,
Dec 9 2016
+hashimoto, +kinaba who are familiar with the code of drag & drop non-native files. After observing the issue, the logic look like: 1. DropData contains two isolate file system: A) Isolated file system for native files B) isolated file system for filesystem API files (e.g. Google Drive file). 2. crrev.com/1723763002 stopped creating the file system A when DropData does not contain native files. It seems correct. 3. The problem is in webkitGetAsEntry() which backs a JS function converting DataTransferItem to FileEntry. Before crrev.com/1723763002 it returns FileEntry that refers the file system A even for filesystem API files, though it must refer the file system B. The returned FileEntry is invalid and we cannot operate file operations for it. 4. After applying crrev.com/1723763002, webkitGetAsEntry cannot refer the file system A thus it start returning null. 5. I'm guessing Google Drive web invokes webkitGetAsEntry. It cannot read data from FileEntry returned by webkitGetAsEntry so it may use getAsFile() instead to read data. After applying crrev.com/1723763002, webkitGetAsEntry returns null. In this case Google Drive seems to skip the file.
,
Dec 9 2016
,
Dec 9 2016
Talked with hashimoto@-san offline. 1. Google Drive web actually invokes webkitGetAsEntry. (Maybe to handle folder drop?) 2. To fix webkitGetAsEntry, we need to pass fileSystemId of the file system B to render processes.
,
Dec 12 2016
Fix was uploaded. crrev.com/2565283002.
,
Dec 14 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/da08349d4b87496c619152256ab039f6f6d2f28b commit da08349d4b87496c619152256ab039f6f6d2f28b Author: hirono <hirono@chromium.org> Date: Wed Dec 14 07:36:16 2016 Fix webkitGetEntry for non-native files. Previously webkitGetEntry was broken for non-native files. The method creates FileEntry in isolated file system from DataTransferItem. The problem is DataTransferItem only has file system ID of isolated file system containing native files, though the browser process prepares different isolated file system for non-native files. The CL adds new field 'fileSystemId' for types representing a non-native file and let webkitGetEntry refer the fileSystemId so that it can return valid FileEntry for non-native files. BUG= 671811 TEST=Drop a file from Chrome OS Files app to Google Drive web. Review-Url: https://codereview.chromium.org/2565283002 Cr-Commit-Position: refs/heads/master@{#438455} [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/browser/renderer_host/render_view_host_impl.cc [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/browser/renderer_host/render_widget_host_impl.cc [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/browser/web_contents/web_contents_view_aura.cc [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/common/drag_traits.h [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/public/common/drop_data.h [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/renderer/drop_data_builder.cc [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/content/renderer/render_widget.cc [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DataObject.cpp [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DataObject.h [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DataObjectItem.cpp [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DataObjectItem.h [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DataObjectTest.cpp [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DraggedIsolatedFileSystem.cpp [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/core/clipboard/DraggedIsolatedFileSystem.h [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/modules/filesystem/DataTransferItemFileSystem.cpp [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/modules/filesystem/DraggedIsolatedFileSystemImpl.cpp [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/Source/modules/filesystem/DraggedIsolatedFileSystemImpl.h [modify] https://crrev.com/da08349d4b87496c619152256ab039f6f6d2f28b/third_party/WebKit/public/platform/WebDragData.h
,
Dec 15 2016
,
Dec 15 2016
,
Dec 15 2016
can we merge to m56?
,
Dec 15 2016
I think so. Let me send a merge request.
,
Dec 15 2016
Your change meets the bar and is auto-approved for M56 (branch: 2924)
,
Dec 15 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb commit 0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb Author: Daichi Hirono <hirono@chromium.org> Date: Thu Dec 15 07:45:28 2016 Fix webkitGetEntry for non-native files. Previously webkitGetEntry was broken for non-native files. The method creates FileEntry in isolated file system from DataTransferItem. The problem is DataTransferItem only has file system ID of isolated file system containing native files, though the browser process prepares different isolated file system for non-native files. The CL adds new field 'fileSystemId' for types representing a non-native file and let webkitGetEntry refer the fileSystemId so that it can return valid FileEntry for non-native files. BUG= 671811 TEST=Drop a file from Chrome OS Files app to Google Drive web. Review-Url: https://codereview.chromium.org/2565283002 Cr-Commit-Position: refs/heads/master@{#438455} (cherry picked from commit da08349d4b87496c619152256ab039f6f6d2f28b) Review-Url: https://codereview.chromium.org/2582463002 . Cr-Commit-Position: refs/branch-heads/2924@{#508} Cr-Branched-From: 3a87aecc31cd1ffe751dd72c04e5a96a1fc8108a-refs/heads/master@{#433059} [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/browser/renderer_host/render_view_host_impl.cc [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/browser/renderer_host/render_widget_host_impl.cc [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/browser/web_contents/web_contents_view_aura.cc [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/common/drag_traits.h [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/public/common/drop_data.h [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/renderer/drop_data_builder.cc [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/content/renderer/render_widget.cc [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DataObject.cpp [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DataObject.h [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DataObjectItem.cpp [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DataObjectItem.h [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DataObjectTest.cpp [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DraggedIsolatedFileSystem.cpp [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/core/clipboard/DraggedIsolatedFileSystem.h [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/modules/filesystem/DataTransferItemFileSystem.cpp [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/modules/filesystem/DraggedIsolatedFileSystemImpl.cpp [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/Source/modules/filesystem/DraggedIsolatedFileSystemImpl.h [modify] https://crrev.com/0fff0c9efd40d9bbe9bc99fa239a89a4f241fedb/third_party/WebKit/public/platform/WebDragData.h
,
Feb 17 2017
|
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by satorux@chromium.org
, Dec 7 2016Owner: fukino@chromium.org
Status: Assigned (was: Untriaged)