LeGoffMael / insta_assets_picker

An image (and videos) picker similar with Instagram, supports multi picking, crop and aspect ratio.
https://pub.dev/packages/insta_assets_picker
MIT License
79 stars 34 forks source link

Permission state error with PermissionState.denied when using Android API 33. #41

Closed aymanalhalali closed 2 weeks ago

aymanalhalali commented 4 months ago

Hello,

It seems there is an issue after granting permission of photos on Android API 33. Please consider the changes of permission request from API 32 for storage and photos.

E/flutter (11879): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: Bad state: Permission state error with PermissionState.denied.
E/flutter (11879): #0      AssetPickerDelegate.permissionCheck (package:wechat_assets_picker/src/delegates/asset_picker_delegate.dart:40:7)
E/flutter (11879): <asynchronous suspension>
E/flutter (11879): #1      AssetPickerDelegate.pickAssetsWithDelegate (package:wechat_assets_picker/src/delegates/asset_picker_delegate.dart:157:5)
E/flutter (11879): <asynchronous suspension>
E/flutter (11879): #2      openGallery.picker (package:battuta/src/services/gallery_service.dart:48:7)
mohsin2596 commented 1 month ago

This is a wechat related issue. The library is using old wechat version which is not supporting limited permissions

LeGoffMael commented 3 weeks ago

A new release 2.3.1 has been deployed which uses the latest wechat_assets_picker version. Please check it out