-
Notifications
You must be signed in to change notification settings - Fork 24.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CameraRoll.getPhotos breaks with assetType = photos #13671
Comments
Hi zackify, I'm having the same issue. How did you solve it? |
@zackify I'm running into this problem. I noticed you closed it, did you solve it or find a work around, if so what is it? |
It works fine when I call that method in my own component. Doesn't seem to
be a bug with React native but rather that 3rd party library. I did the
exact call to get all media types and it worked fine for me, so I closed.
…On Wed, May 17, 2017 at 00:40 Alex Roman ***@***.***> wrote:
@zackify <https://github.com/zackify> I'm running into this problem. I
noticed you closed it, did you solve it or find a work around, if so what
is it?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#13671 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAbacLzOkSCKjxrHe49ilrOnxkwGRCeXks5r6nozgaJpZM4NI7Hf>
.
|
I am having the same issue with CameraRoll from RN. CameraRoll.getPhotos({
first: 20,
groupTypes: 'All',
assetType: 'Photos'
}).then(r => {
console.log(r);
}).catch((err) => {
console.log('gallery', err);
}); The thing is that some photo for some reason filename is missing (maybe iCloud). And I think its crashing because of that (not completely sure), but as I see @zackify also his filename was nil. It doesn't fail under the simulator, but on my real device, where most of my photos are on iCloud. |
Same Here guys. |
…loud, no filename comes with them and the application crashes
The pull request was approved, it only needs to get merged. |
…ilename is provided. #13671 Summary: RCTCameraRollManager.m crashes when there is no filename provided for the asset (usually from iCloud). #13671 Tested on real device with iCloud library using the library without and after my fix. It worked after my changes. [IOS] [BUGFIX] [CameraRoll] - Changed the filename if nil to be empty when the asset is coming from iCloud. Closes #17549 Differential Revision: D6710665 Pulled By: hramos fbshipit-source-id: 319865b0a71728798c62ee380e7bee4af584b3e3
@pentarex was this update merged? I can not see it in the latest version of RN |
I don’t think. Check my profile for alternative library that I’ve wrote if you want |
@pentarex I did the same update on my project and I think that fixed some cases. But I'm still having errors with iCloud files, I have reported this #18159 It's being difficult to find the reason of this bug because I know that is happening for some people, but I couldn't reproduce it 🤯 if you have any idea or suggestion let me know please! |
@facuescobar except the thing that I've told you, I have no other clue. Also they are using old framework for the Gallery and this is taking the pictures from iTunes, it has some strange ordering, if you want to test out this one be my guest https://github.com/pentarex/react-native-gallery-manager |
Description
I'm using this library: https://github.com/jeanpan/react-native-camera-roll-picker/blob/master/index.js under the hood it calls the cameraRoll api. When I pass in 'All' for the asset type, it works. When I use 'Photos' as the type, the app crashes inside of the RCTCameraRoll code:
Reproduction Steps and Sample Code
I was going to try and add an example on expo, but it won't work unless you have more than just photos in your camera roll. To reproduce, just call
CameraRoll.getPhotos({assetType: 'Photos'})
The text was updated successfully, but these errors were encountered: