Skip to content

fix: #276 scan on iOS crash#278

Open
bradmartin wants to merge 3 commits into
EddyVerbruggen:masterfrom
bradmartin:feat_fix_scan_ios
Open

fix: #276 scan on iOS crash#278
bradmartin wants to merge 3 commits into
EddyVerbruggen:masterfrom
bradmartin:feat_fix_scan_ios

Conversation

@bradmartin
Copy link
Copy Markdown

  • Updates the src and demo to use latest NS and webpack setup.
  • Fix the crash on scan by init the instance of the VolumeObserverClass.

@grigala
Copy link
Copy Markdown

grigala commented Nov 29, 2021

@Atomico001 as @EddyVerbruggen does not seem to have time, could you merge this?

@cristiandaulisio
Copy link
Copy Markdown

@Atomico001 as @EddyVerbruggen does not seem to have time, could you merge this?

I am a simple user, haven't permission to merge. I am waiting for this merge too :)

@bradmartin
Copy link
Copy Markdown
Author

bradmartin commented Nov 29, 2021

https://github.com/nstudio/nativescript-plugins/tree/main/packages/nativescript-barcodescanner

That will have this fix, we decided to go ahead and publish a version with the fix as it is needed in many projects that we work on, when and if Eddy comes back around to doing more OSS then we can merge things back together and have a consistent approach without fragmenting the plugin ecosystem. Sadly, at times, with all OSS that is the only option so for now we plan to try and help manage a version under our scope at @nstudio. If that doesn't work, anyone can take this branch/fork with the fix and npm pack it locally and use a tgz dependency in your application with a relative filepath and it will work the same.

@andrewm-mitchells
Copy link
Copy Markdown

Do we have an idea when this can be merged in and new version released?

@maxximee
Copy link
Copy Markdown

maxximee commented Dec 30, 2022

Will this be merged? ios crashes when I call scan on ios 16.1.2 and I urgently need a fix.

I tried to checkout the forked code to publish it to my local repo but can't build because of those 2 errors:

barcodescanner.ios.ts:257:73 - error TS2693: 'WeakRef' only refers to a type, but is being used as a value here.
257         this._scanDelegate = QRCodeReaderDelegateImpl.initWithOwner(new WeakRef(this));

barcodescanner.ios.ts:506:9 - error TS2304: Cannot find name 'AudioServicesPlaySystemSound'.
506         AudioServicesPlaySystemSound(1519);

@EddyVerbruggen could you merge this, if it fixes the ios crash. Thanks

@grigala
Copy link
Copy Markdown

grigala commented Dec 30, 2022

@maxximee use @nstudio/nativescript-barcodescanner this one is not maintained.

P.S. this has been addressed in the #278 (comment), so please take a time to read previous comments.

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.

5 participants