terminal icon indicating copy to clipboard operation
terminal copied to clipboard

Dragging and dropping paths to terminal stops at 16 items

Open jiejasonliu opened this issue 2 years ago • 5 comments

Windows Terminal version

1.15.2713.0

Windows build number

10.0.22000.0

Other Software

No response

Steps to reproduce

  1. Highlight more than 16 items from an archive (7zip, WinRAR, etc.)
  2. Drag and drop highlighted items into terminal

Expected Behavior

Should write paths equal to the amount of items highlighted

Actual Behavior

Only writes up to 16 paths

jiejasonliu avatar Jan 04 '23 08:01 jiejasonliu

This issue occurs in other UWP or WinAppSDK apps. It appears that the culprit is that GetStorageItemsAsync() from the drag event only returns up to 16 items.

Perhaps this is a bug from WinRT?

jiejasonliu avatar Jan 04 '23 08:01 jiejasonliu

Sure sounds like something outside our control. I'd probably file this at https://github.com/microsoft/WindowsAppSDK/issues? They'd at least have a better way to investigate.

zadjii-msft avatar Jan 04 '23 12:01 zadjii-msft

Makes sense, I'll go ahead and file an issue over there.

Sure sounds like something outside our control.

Despite this being an external issue, is this something that we want to fix? I have a workaround solution that appears to work and can open a PR for.

jiejasonliu avatar Jan 05 '23 00:01 jiejasonliu

I have a workaround solution that appears to work and can open a PR for.

Oh well let's try that! It wouldn't be the first workaround for weird platform behavior in our codebase 😉

zadjii-msft avatar Jan 05 '23 13:01 zadjii-msft

Upon looking into a little further, it appears the issue only occurs when dragging and dropping from archives (7zip, WinRAR, and others). It works fine if you do it from the native file explorer though; probably because it doesn't create any temp files.

I can still open a pull request for this edge case unless you're on the side that it isn't worth fixing.

jiejasonliu avatar Jan 06 '23 05:01 jiejasonliu

I'd love to see the PR! If it's something we can work around, let's do it. Thanks @jiejasonliu

DHowett avatar Jan 06 '23 21:01 DHowett

:tada:This issue was addressed in #14648, which has now been successfully released as Windows Terminal v1.16.1023 (10231 and 10232).:tada:

Handy links:

ghost avatar Jan 24 '23 18:01 ghost

:tada:This issue was addressed in #14648, which has now been successfully released as Windows Terminal Preview v1.17.1023.:tada:

Handy links:

ghost avatar Jan 24 '23 18:01 ghost

Related WindowsAppSDK just for reference https://github.com/microsoft/WindowsAppSDK/issues/3328

KindDragon avatar Feb 01 '23 11:02 KindDragon