WebView2Feedback
WebView2Feedback copied to clipboard
UI sometimes becomes uninteractive with the mouse after selecting a file from a file input (.NET MAUI Blazor)
Issue moved from dotnet/maui#15072
- Please respond to @DennisvHest.
From @DennisvHest on Saturday, May 13, 2023 8:07:59 PM
Description
Sometimes after selecting a file using a file input, the application can no longer be interacted with using the mouse. The application is not frozen however, because you can still interact with the keyboard.
It happens very inconsistantly. Sometimes I can reproduce it immediately, other times I have to select like 20 files before the bug occurs.
Once the bug occurs, the mouse interactivity can be restored by moving the mouse cursor out of the window. After that you can interact with the mouse again.
UPDATE (14-01-2024): After updating to .NET 8, instead of the original bug occuring, the application crashes.
https://github.com/dotnet/maui/assets/18610083/28ba1536-86ce-4245-acaf-636b8fd051b1
Steps to Reproduce
- Create a File > New .NET MAUI Blazor App
- Add the following code to the index.razor page:
@page "/"
<input type="file" />
<b>Counter: @counter</b>
<button @onclick="IncrementCount">count</button>
@code {
int counter = 0;
void IncrementCount()
{
counter++;
}
}
- Select a file using the file input
- Try to click the count button
- If you can still click the count button, repeat steps 3 and 4 (it might take like 20 times for the bug to occur)
- If the bug occurs (count button cannot be clicked), move the mouse outside of the window
- The count button can now be clicked again
Expected outcome: page stays interactive Actual outcome: page is no longer interactive using the mouse .NET 8 Update: application now crashes when this occurs
Link to public reproduction project repository
https://github.com/DennisvHest/FileInputBugTest
Version with bug
8.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
Windows
Affected platform versions
Windows 10 22H2, Windows App SDK 1.3.230502000
Did you find any workaround?
Haven't found a workaround for this.
Relevant log output
No response
Issue moved from dotnet/maui#15072
- Please respond to @Makstvell.
From @Makstvell on Tuesday, May 16, 2023 10:47:21 AM
I have same problem , when i fast input text to and change focus to other . App becomes uninteractive!!!
Issue moved from dotnet/maui#15072
- Please respond to @DennisvHest.
From @DennisvHest on Tuesday, May 16, 2023 11:07:56 AM
I have same problem , when i fast input text to and change focus to other . App becomes uninteractive!!!
@Makstvell I had this issue aswell at first, but this has been fixed in an update to the Windows App SDK. You will have to manually update this in your application. https://github.com/MicrosoftEdge/WebView2Feedback/issues/3003#issuecomment-1499349079
This issue might be related. I wasn't sure where to post this issue. I only use webview2 via .NET MAUI Blazor.
Issue moved from dotnet/maui#15072
- Please respond to @Makstvell.
From @Makstvell on Tuesday, May 16, 2023 11:15:58 AM
@DennisvHest Thank you very much. It works.
Issue moved from dotnet/maui#15072
- Please respond to @mkArtakMSFT.
From @mkArtakMSFT on Wednesday, May 17, 2023 4:48:46 PM
Thanks for helping out with this, @DennisvHest !
Issue moved from dotnet/maui#15072
- Please respond to @DennisvHest.
From @DennisvHest on Wednesday, May 17, 2023 4:58:59 PM
@mkArtakMSFT Why is this closed? My comment to @Makstvell was about a different issue. That other issue was fixed, but this issue still persists.
Issue moved from dotnet/maui#15072
- Please respond to @Makstvell.
From @Makstvell on Thursday, May 18, 2023 12:04:17 PM
@DennisvHest One more question, do you know how to fix when sometimes when open app -> black screen?
Issue moved from dotnet/maui#15072
- Please respond to @Makstvell.
From @Makstvell on Thursday, May 18, 2023 12:05:59 PM
@mkArtakMSFT issue can't be closed, because other issue was fixed.
Issue moved from dotnet/maui#15072
- Please respond to @DennisvHest.
From @DennisvHest on Thursday, May 18, 2023 5:44:22 PM
@DennisvHest One more question, do you know how to fix when sometimes when open app -> black screen?
@Makstvell No, I don't know. I have not experienced that issue in my project.
Issue moved from dotnet/maui#15072
- Please respond to @Eilon.
From @Eilon on Friday, August 4, 2023 11:36:54 PM
There is this WebView2 issue with <input type="file"> that can cause the app to crash: https://github.com/MicrosoftEdge/WebView2Feedback/issues/3551
I wonder if the root issue is the same?
Issue moved from dotnet/maui#15072
- Please respond to @Eilon.
From @Eilon on Saturday, January 13, 2024 12:28:25 AM
Confirmed still repros with .NET 8.
Issue moved from dotnet/maui#15072
- Please respond to @DennisvHest.
From @DennisvHest on Sunday, January 14, 2024 6:28:20 PM
I have updated the reproduction project to .NET 8. Issue still persists, however now the application crashes instead of not being interactive using the mouse.
I cannot view the exception. Visual studio shows me this window:
Issue moved from dotnet/maui#15072
- Please respond to @ghost.
From @ghost on Thursday, January 18, 2024 6:18:29 AM
Hi @DennisvHest. We have added the "s/try-latest-version" label to this issue, which indicates that we'd like you to try and reproduce this issue on the latest available public version. This can happen because we think that this issue was fixed in a version that has just been released, or the information provided by you indicates that you might be working with an older version.
You can install the latest version by installing the latest Visual Studio (Preview) with the .NET MAUI workload installed. If the issue still persists, please let us know with any additional details and ideally a reproduction project provided through a GitHub repository.
This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.
Issue moved from dotnet/maui#15072
- Please respond to @Zhanglirong-Winnie.
From @Zhanglirong-Winnie on Thursday, January 18, 2024 6:19:41 AM
Verified this issue with Visual Studio Enterprise 17.9.0 Preview 3. the original problem does not repro, but the problem still recurs after the update.
Issue moved from dotnet/maui#15072
- Please respond to @Eilon.
From @Eilon on Saturday, January 20, 2024 12:58:15 AM
I have updated the reproduction project to .NET 8. Issue still persists, however now the application crashes instead of not being interactive using the mouse.
I cannot view the exception. Visual studio shows me this window:
That is the behavior I 'expect' if the app is run with the debugger attached, and it's the issue I linked earlier: https://github.com/MicrosoftEdge/WebView2Feedback/issues/3551
But I was able to repro the original issue when I ran the app without the debugger attached. After closing the file dialog it would sometimes ignore several mouse clicks.
They could be the same underlying issue, but I'm not certain.
Thank you for reporting this! I am tracking this on our side
