Skip to content
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

Handled the Crash:App crashing - RuntimeException: getParameters fail… #1002

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rdfordatascience-ops
Copy link

@Redth Created a PR which just adds a try catch block to avoid one weird Camera getparameter crash when we open the scanner in prism navigation. This try catch will just eat the exception and allows the system to continue scanning

@dantovalphas
Copy link

Hello @rdfordatascience-ops, i hope you're ok, u can publish a package with this correction or exist one yet?

@mos379
Copy link

mos379 commented Feb 11, 2023

@Redth any chance this getting included?

@Jerome-Liger
Copy link

5 years this issue persists, and it's not acceptable for our applications to CRASHE violently in production :-(
As nobody move... so I will.

Related Issues : #728 #924 #1011 (and maybe more ? I stopped my search here...)

A pull request #1002 has been kindly submitted by @rdfordatascience-ops (thanks ;-)) but has never been merged, accepted or included in a new version...
It's not a "clean" solution, but it's better than CRASHES.

So :

  • I forked this repo (https://github.com/Respawnsive/ZXing.Net.Mobile)
  • I've applied the PR 1002 :
    • Just a "try-catch" block for not CRASHING our apps
    • Apparently, it continues to works normaly even after an exception raised here... (@rdfordatascience-ops you can confirm ?)
  • I've deleted some target platforms (I don't have time to install all the SDKs required for platforms that nobody use ;-)) :
    • Tizen
    • MacOS
    • Windows UAP
    • (so I only keep .netStandard/Android/iOS
  • I build successfully, generate NuGetPackages and publish them :

https://www.nuget.org/packages/Respawnsive.ZXing.Net.Mobile/
https://www.nuget.org/packages/Respawnsive.ZXing.Net.Mobile.Forms/

-> 1 hour, that's all what it takes to me...

So I hope this will be usefull for some peoples... because the "real production world" is not focused on MAUI (not yet at least ;-))
Regards

@mos379
Copy link

mos379 commented Feb 14, 2023

@Jerome-Liger this is awesome! Thanks.
Wish @Redth would simply approve the pull requests as beta or enable someone else to contribute...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants