Open ithieund opened 7 years ago
Unfortunately I don't have mentioned device, and therefore I cannot reproduce and fix these bugs. Do you have some time to debug it and try to fix it?
Thanks
@ivpusic , It seems that the log is created by the plugin and I'm not familiar with reading plugin code so fixing this is impossible for me :(
Do you have any idea about the bug with the log I provided? Ex: which file writes that log and what can be the causes?
I'll try to test it on AVD to see if I can reproduce the bugs on this device and let you know.
Thanks.
first error is a message defined in this file https://github.com/ivpusic/react-native-image-crop-picker/blob/master/android/src/main/java/com/reactnative/ivpusic/imagepicker/PickerModule.java#L54. As you can see constant is used on multiple places, so you could put breakpoints on few places and try to figure out what is happening.
The second error is coming from this line https://github.com/ivpusic/react-native-image-crop-picker/blob/master/android/src/main/java/com/reactnative/ivpusic/imagepicker/PickerModule.java#L475.
Let me know if you need more help.
@ivpusic , Thank you very much for your suggestion, but I don't know how to debug java code with ReactNative, can you give me some instruction please?
There's some updates:
Then I think there was some problem with the Android OS in Huawei Phone.
Thanks.
you will need android studio. Import your RN project into it, and then you will be able to run it with android studio and debug it
@ivpusic , Thanks, I'll try it. But will debugging work with physical device, like my Huawei Phone?
yes
@ivpusic I found 2 bugs with your plugin in my Huawei GR5 device (Andoid 6.0.1)
Bug #1: When clicking the menu Gallery in the picker multiple times (sometimes I only need to click it 2 times to reproduce the bug) then the picker will disappear and return to the app with nothing. This is the log: W/ReactNativeJS(20807): User cancelled image selection W/ReactNativeJS(20807): createErrorFromErrorData@http://localhost:8081/index.android.bundle?platform=android&dev=true&ho t=false&minify=false:3622:20 W/ReactNativeJS(20807): http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3585 :59 W/ReactNativeJS(20807): __invokeCallback@http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false& minify=false:3969:15 W/ReactNativeJS(20807): http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3821 :24 W/ReactNativeJS(20807): guard@http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=fals e:3740:3 W/ReactNativeJS(20807): invokeCallbackAndReturnFlushedQueue@http://localhost:8081/index.android.bundle?platform=android& dev=true&hot=false&minify=false:3820:6
W/ReactNativeJS(20807): invokeCallbackAndReturnFlushedQueue@[native code]
Bug #2: When I select a video using Files menu (as Gallery does not work), it returns with nothing. This is the log: W/ReactNativeJS(20807): Invalid image selected W/ReactNativeJS(20807): createErrorFromErrorData@http://localhost:8081/index.android.bundle?platform=android&dev=true&ho t=false&minify=false:3622:20 W/ReactNativeJS(20807): http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3585 :59 W/ReactNativeJS(20807): __invokeCallback@http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false& minify=false:3969:15 W/ReactNativeJS(20807): http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false:3821 :24 W/ReactNativeJS(20807): guard@http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=fals e:3740:3 W/ReactNativeJS(20807): invokeCallbackAndReturnFlushedQueue@http://localhost:8081/index.android.bundle?platform=android& dev=true&hot=false&minify=false:3820:6 W/ReactNativeJS(20807): invokeCallbackAndReturnFlushedQueue@[native code]
Can you please fix this soon? Thanks.