r/Outlook • • 25d ago

Status: Open Drag + Drop upload issues with Classic

Hi everyone, got an issue with someone being unable to drag + drop from Outlook [Classic] to upload attachments into a web-based cloud document/client manager.

Files are still copying to desktop, File Manager, and other web-based services that allow you to upload that way.

What I've tried:

- Different browser [nope]
- Drag + drop upload from different source [works, see below]
- Different device [at least, it's working on mine and some others, so it's not *Client Manager*'s issue, but a device/Outlook one]
- Updating Windows [nope]
- Starting Outlook in safe mode [nope]
- Cached mode/non-cached mode [nope]
- Reinstalling Outlook completely [nope]

I'm not gonna lie, this is stressing me out a bit. The user does deal with a high volume of attachments that need to be uploaded to the cloud, and we've continued using Classic because of the usual reasons and also because it does allow us to cut down on the in-between ferrying.

Usually when we upload, a small icon of what kind of file for single ones or an icon showing the number of files for multiple pops up during the hover at the destination. We're not seeing that, but files are still previewing, so I'm unsure if it's a. Local retention thing or what?

Any help would be appreciated.

2 Upvotes

21 comments sorted by

View all comments

Show parent comment

1

u/magicdragin 19d ago • Heartwarming

In case Canopy support hasn't tracked it down yet, I took another look. The error:

Failed to execute 'getFile' on 'FileSystemFileHandle': An attempt was made to break through the security policy of the user agent.

helped me track it down to what I believe is the root cause.

It looks like it wasn't an Outlook change, but rather a change introduced in Chrome/Edge 157 (released Nov 3).

When you drag an email or attachment out of classic Outlook, it provides the dragged items as virtual files, where the file contents are passed to Chrome without an actual file on disk. Chrome writes the files to %TEMP% (%LOCALAPPDATA%\Temp) then hands those temp paths to the page as the dropped files (web_contents_view_aura.cc:1846).

Pages can read a dropped file through either the older File API or the newer File System Access “file handle” API. A recent change introduced in Chrome 157 added a security check when the file handle is used, so that the above error is thrown if the file is under a sensitive folder, including everything under %LOCALAPPDATA%. Throwing the error for drag and drop temp files seems like an issue inadvertently introduced by that change.

I verified this with a test page: reading a dropped Outlook email through a file handle works in Chrome 156 and fails with this error in 157.

Canopy’s drag and drop uses react-dropzone, which uses the file-selector library to read dropped files. Canopy’s version always reads through the file handle while newer versions use the older File API instead. That change was made to fix an Electron issue, but it avoids this problem too. So Canopy should be able to work around it by upgrading react-dropzone.

The Chromium change that broke this is behind a feature flag that is on by default, but can be disabled by running with the command line flag --disable-features=FileSystemAccessDirectoryIterationBlocklistCheck. I verified that using this flag fixes the issue in Chrome 157. So for now you could use that as a workaround, though it might be safest to run it as a separate Chrome instance with its own --user-data-dir where you only use Canopy.

2

u/VampMansionPoolBoy 19d ago

you are a god amongst us. thank u for my life and sanity. im honestly not 100% comfortable with trying to run browsers with command line flags at the moment bc i'm too much of a dumbass and will need to practice before sending out the fix.

buuuuuut i do have the basic ability to logic despite it being monday morning! which meant that my brain went 'ok so if it has to do with chrome/edge and chromium then surely firefox would work right'. and it did!

thank you SO much for your guidance. i will now go be annoying to their support team and probably also on their community boards!

1

u/magicdragin 19d ago

You are too kind, I'm happy to help! I just happen to have a special interest in all things drag and drop.

2

u/Gullible_Dig_9656 15d ago

You are a godsend! My co worker spent most his day yesterday on this issue, I hopped on the end users machine to try and resolve it, and eventually came accross your fix!

1

u/magicdragin 15d ago edited 14d ago

Thanks!

I have a drop inspector page at https://magicdragin.app/drop-inspector that shows what data is available when you drop files onto a web page. I added a check for this file handle issue so you can see if you've been able to work around it correctly it via another browser version or with the feature flag. Hope it helps!

1

u/magicdragin 10d ago

I think this Chromium bug covers the issue: https://issues.chromium.org/issues/584839869

It looks like it should be fixed in Chrome 159 (stable release scheduled for Dec. 8), and awaiting approval to be included in a Chrome 158 patch.