react-native-image-crop-picker icon indicating copy to clipboard operation
react-native-image-crop-picker copied to clipboard

Permission Error

Open ajay2966 opened this issue 2 years ago • 15 comments

error: cannot find symbol permissionsCheck(activity, promise, Collections.singletonList(Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU ? Manifest.permission.WRITE_EXTERNAL_STORAGE : Manifest.permission.READ_MEDIA_IMAGES), new Callable<Void>() { ^ symbol: variable TIRAMISU location: class VERSION_CODES

  • Android

Expected behaviour

Actual behaviour

Steps to reproduce

Attachments

// stacktrace or any other useful debug info

Love react-native-image-crop-picker? Please consider supporting our collective: 👉 https://opencollective.com/react-native-image-crop-picker/donate

ajay2966 avatar Feb 15 '23 08:02 ajay2966

Regarding the Manifest.permission.READ_MEDIA_IMAGES, probably its missing in the Manifest file and adding it there should be enough. If not, maybe it is needed to upgrade some dependency. Same applies for the "TIRAMISU" error. I had to fork the project and replace these variables with the respective direct values until this is fixed.

dariofilipe95 avatar Feb 16 '23 15:02 dariofilipe95

I fixed by trying the solution stated here https://github.com/invertase/notifee/issues/561

dark-matter08 avatar Feb 26 '23 07:02 dark-matter08

@ajay2966 @dariofilipe95 use react-native-image-crop-picker version 0.36.2 It will be fixed. as new version creating permission issues in android

zahid502 avatar Feb 28 '23 15:02 zahid502

Regarding the Manifest.permission.READ_MEDIA_IMAGES, probably its missing in the Manifest file and adding it there should be enough. If not, maybe it is needed to upgrade some dependency. Same applies for the "TIRAMISU" error. I had to fork the project and replace these variables with the respective direct values until this is fixed.

this one fixed my issue, using latest version 0.39 with android 13 and RN 0.71

otskarli avatar Mar 01 '23 12:03 otskarli

You should change your sdkVersion compileSdkVersion = 33 and targetSdkVersion = 33 Gradle upgrade is required as well.

tunm1228 avatar Mar 03 '23 09:03 tunm1228

Just Add <uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/> in your AndroidManifest.xml file.

Regarding the Manifest.permission.READ_MEDIA_IMAGES, probably its missing in the Manifest file and adding it there should be enough. If not, maybe it is needed to upgrade some dependency. Same applies for the "TIRAMISU" error. I had to fork the project and replace these variables with the respective direct values until this is fixed.

aviral1518 avatar Mar 23 '23 13:03 aviral1518

Just Add <uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/> in your AndroidManifest.xml file.

Regarding the Manifest.permission.READ_MEDIA_IMAGES, probably its missing in the Manifest file and adding it there should be enough. If not, maybe it is needed to upgrade some dependency. Same applies for the "TIRAMISU" error. I had to fork the project and replace these variables with the respective direct values until this is fixed.

Thank you very much, this is working for me.

humayunkabir avatar May 16 '23 14:05 humayunkabir

@aviral1518 This dont work for me

VictorPulzz avatar May 18 '23 16:05 VictorPulzz

@VictorPulzz Add Permission in AndroidManifest.xml

remove/add according to your requirement

change react-native-image-crop-picker to 0.38.1 as newer version is having permission issues.

ShoaibMirzaa avatar Jun 16 '23 07:06 ShoaibMirzaa

I have added : <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/> to android/app/src/main/AndroidManifest.xml and downgraded the version to 0.39 and it works for me.

Makhdoom-Sharif avatar Jun 24 '23 01:06 Makhdoom-Sharif

I faced the same issue. I changed android/build.gradle file targetSdkVersion from 31 to 33 & compileSdkVersion from 31 to 33. It worked for me.

I found the solution from here

shyamaprasadk avatar Jul 05 '23 08:07 shyamaprasadk

Just Add <uses-permission android:name="android.permission.READ_MEDIA_IMAGES"/> in your AndroidManifest.xml file.

Regarding the Manifest.permission.READ_MEDIA_IMAGES, probably its missing in the Manifest file and adding it there should be enough. If not, maybe it is needed to upgrade some dependency. Same applies for the "TIRAMISU" error. I had to fork the project and replace these variables with the respective direct values until this is fixed.

Thanks dude work for me

vaibhavshah0201 avatar Jul 20 '23 08:07 vaibhavshah0201

Possible Unhandled Promise Rejection (id: 4): Error: User did not grant camera permission. after setting all permissions this error is showing

Adil7767 avatar Aug 21 '23 11:08 Adil7767

How can I make this work in Expo?

hurshore avatar Oct 11 '23 10:10 hurshore

@VictorPulzz Add Permission in AndroidManifest.xml

remove/add according to your requirement

change react-native-image-crop-picker to 0.38.1 as newer version is having permission issues.

Thanks for this suggestion.

I have fixed by error by degrading version to 0.38.1. Don't forget to rebuild your project otherwise, you'll have the same issue.

mianaamirshehzad avatar Oct 19 '23 11:10 mianaamirshehzad