question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

MediaPicker.CapturePhotoAsync crash on the Kyocera C6930

See original GitHub issue

Description

Normally upon calling MediaPicker.CapturePhotoAsync the camera pops up and allows the user to take a photo. However, on a Kyocera C6930 with the default camera settings the app crashes about 7/10 times right after taking a picture. There usually seems to be a pause or stutter when the crash happens. The linked solution works on all tested devices except for the Kyocera C6930.

A strange behavior worth noting is that the frequency of crashing goes down if I set the resolution to be the lowest amount and the “Auto HDR”/“Auto Night Detection” settings to off. I don’t know if there is a different method I could use to try taking photos which might get us around this issue.

I am including a very simple app which just takes a picture and displays it. It should work fine on most things, but crashes almost every time a picture is taken on a Kyocera C6930. The device log was too long to submit. I can include certain lines if you tell me what to look for.

Steps to Reproduce

  1. Use a Kyocera C6930
  2. Create a new .NET MAUI App (or use included reproduction app)
  3. Make sure the camera settings are the default settings
  4. Call MediaPicker.CapturePhotoAsync(new MediaPickerOptions { Title = “Take the shot” }) // passing in null behaves the same here

Link to public reproduction project repository

https://github.com/scottteague/photo1

Version with bug

6.0.400

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

6.0.486/6.0.400 (All the way back to Xamarin)

Did you find any workaround?

Not a complete workaround: When the photo resolution is set to medium and the “Auto HDR”/“Auto Night Detection” settings are turned off it crashes slightly less often.

I’d love to try a different workaround if you know of one.

Relevant log output

*The device log is far too long to include here, I have put it into the example repository 

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6

github_iconTop GitHub Comments

1reaction
msftbot[bot]commented, Oct 6, 2022

We’ve moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.

1reaction
scottteaguecommented, Oct 5, 2022

I have made a commit which has the device logs since they are so large that they could not be added to the issue via the web page.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Xamarin MediaPicker CapturePhotoAsync restarting the ...
MediaPicker CapturePhotoAsync () method. Some users of an application of mine have been going through silent crashes that restarts the app ...
Read more >
Xamarin Essentials MediaPicker crashing after taking a ...
I'm testing taking pictures with the camera to set a profile pictures on an Android phone. After taking the photo and clicking the...
Read more >
Xamarin MediaPicker CapturePhotoAsync restarting the ...
MediaPicker CapturePhotoAsync () method. Some users of an application of mine have been going through silent crashes that restarts the app ...
Read more >
Untitled
... Operating instructions for C6930 MediaPicker.CapturePhotoAsync crash on the Kyocera C6930 Error Code: 2013. Lost connection to MySQL server during query ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found