MicrosoftEdge / MicrosoftEdge/WebView2Feedback
WPF FileNotFoundException on initialisation
Open
Nobody has claimed this yet.
bug
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
Description
Hello!
We're seeing FileNotFoundExceptions occurring a low level (~0.1% of uses) during the initialisation routine. It's not clear from the exception what exactly can't be found.
The users who are getting this exception are also using it without a problem in the same session.
Anyone have any idea what might be happening here?
Thanks!
Version
SDK: 1.0.1518.46
Runtime: 109.0.1518.78
Framework: WPF
OS: Windows 10
Repro Steps
We haven't been able to reproduce this
Additional Context
- We're currently packaging
WebView2Loader.dllat root level and not inruntimes\win-x86\native, though that shouldn't be an issue asCoreWebView2Environment.LoadWebView2LoaderDll()specifically checks the app root level, as well as theruntimespath - We're using
CoreWebView2Environment.GetAvailableBrowserVersionString()to verify that a user has WebView2 installed on their machine before continuing, which finishes without throwing every time
Stack Trace
System.IO.FileNotFoundException: The system cannot find the file specified. (Exception from HRESULT: 0x80070002)
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
at Microsoft.Web.WebView2.Core.CoreWebView2Environment.<CreateCoreWebView2ControllerAsync>d__8.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at Microsoft.Web.WebView2.Wpf.WebView2.<>c__DisplayClass33_0.<<EnsureCoreWebView2Async>g__Init|0>d.MoveNext()
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.