votrai123 / integrate-multiple-react-native

8 stars 4 forks source link

react-native-image-crop-picker cannot pick image when miniapp bundle (android only) #8

Closed NguyenManh1404 closed 8 months ago

NguyenManh1404 commented 8 months ago

Describe the bug

Mình sử dụng thư viện react-native-image-crop-picker. Để upload ảnh cho app. Function đó đã chạy cho cả 2 app cha và con ở trạng thái chưa bundle. Nhưng khi tiến hành bundle app con, sau đó dùng app cha đá qua thì chức năng upload ảnh bị fail.

App cha con đều dùng: react-native: 0.61, react-native-image-crop-picker: 0.36.0.

English I use react-native-image-crop-picker library. To upload photos to the app. That function has been run for both parent and child apps in the unbundled state. When bundling the child app. Then when using the app, the photo upload function fails.

Both father and son use the app: react-native: 0.61, react-native-image-crop-picker: 0.36.0.

votrai123 commented 8 months ago

Can you help me upload the images or video demo error? And describe the specific error @NguyenManh1404

NguyenManh1404 commented 8 months ago

Video bug when switch from parent app to miniapp(android only). On ios flatform is work ok. This bug also happen on real devices !

When child app has not been bundled. Then function upload image is work @votrai123

Error bug cannot show on metro because miniapp is bundled. But I log by logcat have native module mess:

if (promise == null) { Log.w("image-crop-picker", "Trying to notify success but promise is not set"); return false; }

I don't know promise is null. Can you have me

https://github.com/votrai123/integrate-multiple-react-native/assets/74901875/14517083-339a-44bd-b117-3a081468c74c

votrai123 commented 8 months ago

You may have an error with the NODEJS version. You can try v14.21.3 for react native 0.61 or Because the React native version does not map with the third library @NguyenManh1404

NguyenManh1404 commented 8 months ago

Thanks you a lot. I must be to fix on native library react-native-image-croper-picker