-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
[Bug] FilePicker throws System.InvalidOperationException: 'Window Not Found' #2102
Comments
I am seeing the same issue on Preview 7 on Android, in my case when attempting to open a custom tab via MSAL.NET. I've tried with the embedded browser as well, same issue, so it seems to be related to the launching of any new activity, or more specifically, the default MAUI OnResume callbacks. Here is a full stack trace upon crash. It appears that something in the MAUI OnResume handlers could be passing the wrong Window object up the chain?
At the moment the new activity is created, the following log code added to OnResume:
returns this:
I do see new PR activity around CreateWindow in #2035 by @mattleibow, but it didn't make it into Preview 7, and seems to revolve around more of an app launch timing issue than anything. |
+1 from me. I'm getting the issue when trying to acquire a token using MSAL.NET in Microsoft.Identity.Client v.4.35.1 (which was working fine in Preview 6). More details supplied in #2154 - #2154 (comment) Cheers, Paul |
Same here with WebAuthenticator
It worked on preview 6, but not on 7. |
Having a look at that stack trace I think we fixed that shortly after releasing P7. It should be fixed in RC1. You can test out the current CI builds using this Wiki: |
As an FYI - in case it helps anyone, I have some notes I made on installing the CI build of RC1 here. |
I believe I'm seeing the same issue when calling MediaPicker.CapturePhotoAsync(). I'll probably wait until RC1 is released. I'm assuming it should be out in the next week or so. Am surprised this one made it into the wild because it impacts such a wide range of calls. |
This bug still persist on preview 9. Is there a temporary workaround atm? Thank you |
I too am experiencing issues with this still. I see its still being tracked open and that there is a link to a fix. Is that fix set to go live later this month when preview 11 comes out? |
Description
In maui preview7 on android, whenever call
FilePicker.PickAsync();
method the maui application will throwSystem.InvalidOperationException: 'Window Not Found'
and crash.Steps to Reproduce
await FilePicker.PickAsync();
in button onclick event handler and start debugExpected Behavior
the filepicker shows up
Actual Behavior
the filepicker shows up, then the app throws
System.InvalidOperationException: 'Window Not Found'
and crash.Basic Information
Screenshots
Reproduction Link
https://github.com/Chronostasys/ButtonTest
Workaround
The text was updated successfully, but these errors were encountered: