Your workflow is unique 👨💻 - tell us how you use Dropbox here.
Forum Discussion
Sergey S.10
9 years agoNew member | Level 1
Video thumbnails are not generated anymore
Some days ago we found that video thumbnails are not displayed in our app. iOS app uses official cocoapod Dropbox-iOS-SDK (version 1.3.13). At some step it displays media content of user's Dropbox folders: images and videos. We get and display thumbnails for images and videos using method
-loadThumbnail:ofSize:intoPath
During last several months it worked for both videos and images, but some days ago it logs warning and return error in callback for videos:
[WARNING] DropboxSDK: error making request to /1/thumbnails/dropbox/camera uploads/.../X.mov - (415) permanent failure - this image isn't supported by thumbnailing
I understand that SDK officially should support only some image file types for files less than 20Mb. I don't understand why you turned this feature off for other file types: it was implemented and it worked well.
Please turn this feature on and officially declare this support in documentation. I can't imagine that the most famous cloud service SDK doesn't support thumbs for videos. How we should display these videos in our apps?
22 Replies
Replies have been turned off for this discussion
- Greg-DB9 years ago
Dropbox Community Moderator
Thanks for writing this up! That's correct, the API doesn't currently officially support video thumbnails, so I'm sending this along as a feature request.
- James K.369 years agoNew member | Level 1
Hi Gregory.
Can you please help provide some additional context around this. We have an app that was recently feature by Apple as one the the "Best New Apps" and our integration with Dropbox is a major feature for our users. It gave them easy and quick access to their media on Dropbox, including videos.
Up until recently, these users could easily browse their Dropbox files and easily select the media they wanted because all videos and images returns thumbnails. Now, they have no visibility into the files they are browsing.
This is obviously a challenge for us and the users that we share. Adding to the confusion is that through the native Dropbox app, thumbnails continue to be returned for all images and videos.
Thanks in advance for your additional comments on this issue.
James Kupernik
Solutions Architect
VidMob, Inc. - Greg-DB9 years ago
Dropbox Community Moderator
Hi James, unfortunately I don't have any additional information on this right now. I'll send this along to the team though.
- Ken E.49 years ago
Dropbox Staff
Hi Sergey & James,
We believe the issue has been resolved. Could you let us know if you're still seeing this regression?
- James K.369 years agoNew member | Level 1
Hi Ken
i just tested via the VidMob app and still seeing the same result of no thumbnails being returned for video files.
Thanks,
James
- Greg-DB9 years ago
Dropbox Community Moderator
Hi James, thanks for checking that. Can you share the relevant code snippet to reproduce this, so we can make sure we're addressing this properly? Thanks in advance!
- James K.369 years agoNew member | Level 1
Hi Gregory
Our iOS developer is out until tomorrow, but I believe this is the section of code being called.
PerformSync(^{
[DropBlocks loadThumbnail:self.metadata.path
ofSize:imageSize
intoPath:localPath
completionBlock:^(DBMetadata *metadata, NSError *error)
{
completionBlock([UIImage imageWithContentsOfFile:localPath]);
}];
});
Thanks!
- Greg-DB9 years ago
Dropbox Community Moderator
Thanks! We're looking into it. If you can also share some sample values for self.metadata.path and imageSize though, that may also be helpful, just to make sure we're reproducing this exactly the same way.
- James K.369 years agoNew member | Level 1
Gregory
If this next snippet doesn't make sense, i'll have to wait for Sergey to weigh in tomorrow, but here is the method in the Dropbox-iOS-SDK-Source that is being called.
- (void)loadThumbnail:(NSString *)path ofSize:(NSString *)size intoPath:(NSString *)destinationPath
{
NSString* fullPath = [NSString stringWithFormat:@"/thumbnails/%@%@", root, path];
NSString* format = @"JPEG";
if ([path length] > 4) {
NSString* extension = [[path substringFromIndex:[path length] - 4] uppercaseString];
if ([[NSSet setWithObjects:@".PNG", @".GIF", nil] containsObject:extension]) {
format = @"PNG";
}
}
NSMutableDictionary* params = [NSMutableDictionary dictionaryWithObject:format forKey:@"format"];
if(size) {
[params setObject:size forKey:@"size"];
}
NSURLRequest* urlRequest =
[self requestWithHost:kDBDropboxAPIContentHost path:fullPath parameters:params];
DBRequest* request =
[[[DBRequest alloc]
initWithURLRequest:urlRequest andInformTarget:self selector:@selector(requestDidLoadThumbnail:)]
autorelease];
request.resultFilename = destinationPath;
request.userInfo = [NSDictionary dictionaryWithObjectsAndKeys:
root, @"root",
path, @"path",
destinationPath, @"destinationPath",
size, @"size", nil];
[imageLoadRequests setObject:request forKey:[self thumbnailKeyForPath:path size:size]];
}
- Sergey S.109 years agoNew member | Level 1
Hi Gregory and Ken,
Thanks for your attention to this issue. Here are some details on how we reproduce this issue.
We use method:
- (void)loadThumbnail:(NSString *)path ofSize:(NSString *)size intoPath:(NSString *)destinationPath
of class DBRestClient from official cocoapod Dropbox-iOS-SDK (version 1.3.13). Parameters:
path (self.metadata.path): "/camera uploads/2/2014-04-10 18.51.53.mov"
size: "l" (lowercase L)
destinationPath: ".../tmp/l-2014-04-10 18.51.53.mov" (... is just for short)And we got this error in callback:
Error Domain=dropbox.com Code=415 "(null)" UserInfo={path=/camera uploads/2/2014-04-10 18.51.53.mov, size=l, root=dropbox, error=permanent failure - this image isn't supported by thumbnailing, destinationPath=.../tmp/l-2014-04-10 18.51.53.mov}We get this issue for all videos. Image thumbnailing works for us in all cases.
I've just checked and yes — this issues is still 100% reproducable for us.
Thanks!
Sergey
About Dropbox API Support and Feedback
Get help with the Dropbox API from fellow developers and experts.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!