-
Notifications
You must be signed in to change notification settings - Fork 675
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
Preview2: Crash during drag & drop (0x00007FFBCFD8B362 KernelBase.dll) #7002
Comments
@MikeHillberg do we have a bug link for this one? |
I'm currently not able to repro the crash, perhaps because I'm trying the repro on Win11 rather than Win10. From what I can see of the callstack, I don't see any changes made in WinUI/WinAppSDK after 1.0 in getting DataView. |
@codendone Can you confirm on your platform the shift of the drop zone? For me, the crash was not triggered immediately for this reduced setup. I had to start the application several times in Debug mode and move around on the shifted drop zone (indicated by Move / Copy labels). |
Yes, I needed to offset to the drop zone (which I see is logged as #7008) and I see the Move label along with the "OnDragOver" text in the debug output. But no crash. I still need to try on Win10. |
The crash signature looks like the one reported in #7007. However, on my WinRT C++ based application, I never saw it on WinUI 1.0.2 and 1.0.3. It was triggered quite fast on WinUI 1.1.0-Preview1 and WinUI 1.1.0-Preview2. |
Both reported issues (crash and offset) are still visible in WinUI 1.1.0-preview3 (#7061). |
Just tested it with WinUI 1.1.0. As @ShashankNay already mentioned the issue is still there. Without a working drag & drop, we can not update our application to the WinUI 1.1.0 Release. This is a serious blocker. |
@jschwizer99 We published a service update (1.1.1) with a bug fix. Let us know if finally fixed this tricky bug. |
@marb2000 @gabbybilka @MikeHillberg |
My app also still crashes after upgrading to version 1.1.1. |
Still crashing with v1.1.1, dragging a file from outside my app used to crash 1/10 times in 1.0.3 but from 1.1 onwards its 9/10 times. Had to turn off the feature for the time being rocksdanister/lively#1262 |
@marb2000 I've tested both my full app and the drag & drop demo application as attached to this ticket for version 1.1.1. Both still show the WinRT error message 'Reentrancy was detected in this XAML application' followed by an unhandled exception. I did see the issue both for Release and Debug builds. I always see the exception for the |
@marb2000 Let me know what further information you need. For this typical crash on 1.1.1 Debug, I can supply the 200MB+ dump or the stowed exceptions for the initial d&d crash example project. As further info when trying out all the different versions, apps, and builds. It seems that sometimes the crash is tough to trigger (or not at all > 200 d&d), sometimes a build will crash right away (in sequence). The only stable observation is that my apps and crash example does not show the issue for <= 1.0.4 versions. This is a different signature as of #7231. In order to trigger the issue more frequently a tree/list could be filled with a lot of small objects with drop individual zones. Moving up / down will trigger the issue very fast. That is the layout of my large app that shows it quite frequently. |
@marb2000 Tested 1.1.1. In our app it doesn't solve any drag&drop crashes and even adds some more. I have crash dumps available. How can I send them? |
More drag and drop weirdness: |
Thanks for all this info. Very useful. Updating this thread. We are actively investigating these drag&drop issues (@Scottj1s is actually investing time on it). Some of them looks similar but could have a different root cause. These bugs are very tricky to diagnose and solve, given it can cause collateral issues, but we are making progress! No ETA yet, but we are planning to service it. |
@marb2000 Thank you Miguel and others for looking into these type of issues. That is greatly appreciated. |
@marb2000 |
Accessing DragEventArgs.DataView with 1.1.3 crashes my C# app. Downgrading to 1.0.3 'resolves' the issue. I tried to reproduce the issue in a blank, minimal repo (Visual Studio 2022 latest: "Blank app, Packaged (WinUI 3 in Desktop") but failed. I suspect there are a few side conditions involved which are not easy to catch by a fresh, new repo. |
fix is now available in Windows App SDK 1.2 Preview 1 |
@Scottj1s Can I use SDK 1.2 Preview 1 in production? |
Yes, you can - the corresponding framework package is available in the store |
@wbokkers, my apologies - Windows App SDK Previews are not supported in production: |
@Scottj1s So when will there be a fix in a production ready version? We need the d&d issues to be resolved very badly in our app. What is fix worth if it can't be used in production? |
The only alternative I can think of is to go SelfContained: |
@Scottj1s That's not an option. I looked into that, but I need to change lots of code for this to work. It is a big app that touches every aspect of the life cycle. We also use appinstaller technology for getting updates. |
(Add more details to this bug) - In my case: Windows App SDK 1.1.4:
|
@Scottj1s I've tested my large application with App SDK 1.2.0-preview1. I could no more observe the crashes as reported in this ticket. Many thanks again for the fixes. Unfortunately, during testing, I hit another regression of App SDK v1.1.x that triggers a crash when using colorpickers. The issue is reported in #7239. It would be great if this regression also gets attention so that finally we again have a WinUI that is as stable as App SDK v1.0.x. |
I've discovered a very reliable sample that can reproduce this bug (I think it's this bug but can't verify, explained below) Create a blank app with WinUI3, and drop the 2 files into the solution. |
Describe the bug
Fatal exception during drag & drop with WinUI 1.1.0 Preview2 during either
get_DataView()
orget_Modifiers()
. The same code works fine for WinUI 1.0.3.Besides the hard crash, the drop area seems to be in the incorrect position.
Steps to reproduce the bug
See attached minimal project.
WinUIDragOverCrash.zip
Note: As extracted from a large failing project, the individual blocks may miss functionality (especially the drop handler). The drop handler of the original project contains o lot of async processing of the dropped data.
Compile and start project. Perform several a drag & drop operation. The drop area for WinUI 1.1.0 Preview 2 is not where it should be. On my screen it was on the lower right corner of the application. Move it around on the drop area to provoke calls to OnDragOver().
Debug Output
Stack Trace
Expected behavior
I would expect that
winrt::Microsoft::UI::Xaml::DragEventArgs::DataView()
andwinrt::Microsoft::UI::Xaml::DragEventArgs::Modifiers()
can be accessed in the DragOver event handler without need of switching between threads.Screenshots
Wrong Drop Area of WinUI 1.1.0 Preview 2
NuGet package version
No response
Windows app type
Device form factor
Desktop
Windows version
Windows 10 (21H2): Build 19044, Windows 10 (20H2): Build 19042
Additional context
No response
The text was updated successfully, but these errors were encountered: