Publish to Gallery v3
Submitted by an unknown user
Link to original bug (#717839)
Description
---- Reported by shotwell-maint@gnome.bugs 2011-06-05 03:20:00 -0700 ----
Original Redmine bug id: 3714
Original URL: http://redmine.yorba.org/issues/3714
Searchable id: yorba-bug-3714
Original author: Bruno Girin
Original description:
Follow up enhancement from ticket #1585 (closed) to add a publishing plugin for Gallery v3 as it has a completely different API from v2.
Related issues:
- related to shotwell - Feature #1585 (closed): export to Gallery (Open)
- duplicated by shotwell - Feature #6081: Add publish to gallery3 (Duplicate)
---- Additional Comments From shotwell-maint@gnome.bugs 2013-09-03 16:23:00 -0700 ----
History
Comment 1
Updated by anarcat - over 2 years ago
- Target version set to 0.11
Here is the API in question:
http://codex.gallery2.org/Gallery3:%(=caps)API%:%(=caps)REST%
Sample client code in PHP:
http://github.com/gallery/gallery3-contrib/tree/master/client/
More specifically, this code supposedly deals with individual file uploads:
https://github.com/gallery/gallery3/blob/master/modules/gallery/helpers/item_r est.php
Other examples:
http://codex.gallery2.org/Gallery3:%(=caps)API%:%(=caps)REST%:Examples – sample HTTP headers
http://codex.gallery2.org/Gallery3:%(=caps)API%:%(=caps)REST%:Python – Python code for upload
http://codex.gallery2.org/Gallery3:%(=caps)API%:%(=caps)REST%:Java-Android – java code for uploading
Note that gallery3 makes full use of tags, which is really interesting – basically, we could translate shotwell “events†into gallery3 “albums†and transfer the tags as is!
The API seems simple enough, anybody working on this yet?
Could this be part of 0.11?
Comment 2
Updated by Bruno Girin over 2 years ago
@anarcat: thanks for the links. It's unlikely that I'll be able to get this in 0.11 as I'm already trying to get Gallery v2 support in 0.11. So 0.12 sounds like a more achievable target. On the other hand, if you're willing to contribute a patch in time for 0.11, I'm sure it can be accommodated!
Comment 3
Updated by Lucas Beeler over 2 years ago
-
Target version deleted (
<strike>
_0.11_</strike>
)
Comment 4
Updated by Devin Theriot-Orr over 1 year ago
Hey all,
I'm just starting to use shotwell for a very large photo library. I would love it if you could add Gallery 3 exporting. As it stands, I have to sort the photos in Shotwell, and then delete the actual files before I can dump a particular set of photos to Gallery, which is a PITA.
So, just wanted to let you all know that this plugin will get some use once it's completed. I'm worried that with it as a low priority, it may never get finished.
(If I were a programmer, I would work on it!)
Thanks.
Comment 5
Updated by Adam Dingle over 1 year ago
- Priority changed from Low to Normal
Comment 6
Updated by Joe Sapp about 1 year ago
I've been working on this plugin in my spare time. It's looking like I might have something to show for it by the end of the year.
Comment 7
Updated by Jim Nelson about 1 year ago
That's great, Joe. Keep us apprised of how your work progresses!
Comment 8
Updated by Sylvain GARGASSON 12 months ago
I survey with lot of attention...
Today every export plugins are for closed web site...
I much appreciate want it's come up
Bye ;-)
Comment 9
Updated by Joe Sapp 10 months ago
- % Done changed from 0 to 30
A little status update:
-Uploading media to a Gallery3 site works
-Working on tagging uploaded files, but it may require a change in plugins/common/RESTSupport.vala. I'll try to link to the bug if I file one to change this file.
Comment 10
Updated by Jim Nelson 10 months ago
- Category set to web-sharing
- Target version set to 0.14.0
Great to hear about this progress! Please keep us informed as progress continues. Also, are you storing your work on a public repo? If so, it'd be appreciated if you linked to it here so others can see the direction you're going.
I'm marking this ticket as a candidate for 0.14. If this completes in time, we'd be happy to include this in the next release.
Comment 11
Updated by Joe Sapp 10 months ago
- % Done changed from 30 to 40
I just implemented tagging. See https://github.com/sappjw/shotwell-gallery3 for the code. It still needs some cleaning up and testing.
Comment 12
Updated by Jim Nelson 10 months ago
Sounds good. Let us know if you have any questions!
Comment 13
Updated by Joe Sapp 9 months ago
- % Done changed from 40 to 60
Making progress. I plan to do a bit more testing for handling the error cases, a bit more cleanup, and (ideally) add a few more bells and whistles. Though the last item can wait if it's getting too close to release time. When is 0.14.0 expected to be released?
Comment 14
Updated by Jim Nelson 9 months ago
- Priority changed from Normal to High
Our string freeze is February 25th, so that's a hard deadline for getting this in to 0.14. The sooner the better, of course!
Comment 15
Updated by Joe Sapp 9 months ago
- % Done changed from 60 to 90
I would say the only thing that remains to be done is restricting the type of video that can be uploaded to mpeg videos, but I'm not sure how to do that. Currently if someone tries to do that an HTTP 400 error is posted.
Comment 16
Updated by Jim Nelson 9 months ago
Joe, I forgot that Gallery is not in our core plugins but extras, so technically today's string freeze does not apply to you. However, if you turn in the code now, it will not be translated in time for Shotwell's 0.14 release. I would say keep working on it and testing it and let us know when it's ready.
Comment 17
Updated by Jim Nelson 8 months ago
- Target version changed from 0.14.0 to 0.15.0
Comment 18
Updated by Jim Nelson 8 months ago
- Target version changed from 0.15.0 to 0.16.0
Comment 19
Updated by Jim Nelson 6 months ago
-
Target version deleted (
<strike>
_0.16.0_</strike>
)
Comment 20
Updated by Joe Sapp 5 months ago
Pending a response to this thread, I think this plugin is ready for review.
Comment 21
Updated by Jim Nelson 5 months ago
To carry the discussion from the mailing list to here, why exactly does your plugin need to exclude certain files?
Comment 22
Updated by Joe Sapp 5 months ago
Gallery3 doesn't support some of the video types that Shotwell does. I figure I could save the user some confusion, time, and bytes uploaded by determining this before the upload.
Comment 23
Updated by Jim Nelson 5 months ago
What video types does it support?
One interim solution would be for the Gallery 3 plugin to only support photos. I believe this is already available in the current plugin interface.
Another solution would be to simply ignore those unsupported videos. I would include somewhere in the publishing dialog a warning that some videos were ignored. This warning should be hidden if all media objects can be uploaded.
Is it hardcoded that certain video types are unsupported? Or does (can) the plugin query that information from the server?
Comment 24
Updated by Joe Sapp 5 months ago
Jim Nelson wrote:
What video types does it support?
It supports [those that are supported by Flowplayer](http://flash.flowplayer.org/documentation/technical- facts.html#formats) (FLV, MP4, and F4V), though some have attempted to get around this. Unfortunately, I don't think the server can be queried for this information.
One interim solution would be for the Gallery 3 plugin to only support photos. I believe this is already available in the current plugin interface.
I know I've seen that in another plugin, but I'd prefer to not do this.
Another solution would be to simply ignore those unsupported videos. I would include somewhere in the publishing dialog a warning that some videos were ignored. This warning should be hidden if all media objects can be uploaded.
I'd like to do this, but I'm not sure how (besides uploading all and trying to handle this error). A solution for Issue #4173 (closed) would be helpful, since I'd just be guessing based on the extension.
Considering it would just be a guess based on the extension and the server may have support for a particular video, maybe I'm just better off trying to handle the case where some items couldn't be uploaded. At first glance I'm not sure how to do this. BatchUploader will throw an error and stop if any file has a problem uploading.
Comment 25
Updated by Jim Nelson 5 months ago
Joe Sapp wrote:
Considering it would just be a guess based on the extension and the server may have support for a particular video, maybe I'm just better off trying to handle the case where some items couldn't be uploaded. At first glance I'm not sure how to do this. BatchUploader will throw an error and stop if any file has a problem uploading.
Unfortunately, BatchUploader isn't very good in that regard. This is something we'd like to fix, but it means updating all the plugins, as they would need to present a manifest detailing what uploaded and what did not, and why (if the server provided something more informative than a simple error code).
Unfortunately, that's about the only real solution here if guessing by extension isn't good enough. I don't believe we have any video-type detection in Shotwell itself, we rely on GStreamer for that.
So I guess what you were proposing earlier was for the plugin to have hardwired the server's supported MIME types, and then Shotwell would query the plugin for what MIME types it supported. At that point it works like it does today, where it only shows sharing plugins that support the selected media types. Is that what you're proposing?
Comment 26
Updated by Joe Sapp 4 months ago
Sorry, looking back I see I wasn't very clear. I'd like the plugin to be able to upload both videos and photos. Without a more complicated BatchUploader, I see two options:
- Filter files to be uploaded by file extension or
- Notify the user that "some files" weren't uploaded.
I don't know how I would implement #1 (moved), and it sounds like it's not possible. Is that right?
If this is correct, I'll implement #2 (closed).
Comment 27
Updated by Jim Nelson 4 months ago
I would need to take a closer look at the code (it's been a while), but doesn't the plugin receive a list of files that it then adds to the BatchUploader? Couldn't you filter out the files at that step and only pass the ones you support to the BatchUploader?
Comment 28
Updated by Joe Sapp 4 months ago
Oh, it does...I see it now. I'll do it this way and add an option to disable the check. Thanks!
Comment 29
Updated by Joe Sapp 3 months ago
I think I now prefer displaying some more informative information to the user on an upload failure. The "video-upload-error" branch at the github link in comment 11 has this code in it.
Comment 30
Updated by Joe Sapp 3 months ago
- % Done changed from 90 to 100
I think I'm satisfied with the plugin as it is now. Of course, now I'm sure to find some bugs :)
Check out the master branch of https://github.com/sappjw/shotwell-gallery3 . Please let me know what I can do next to move this forward.
Comment 31
Updated by Jim Nelson 3 months ago
- Status changed from Open to Review
- Target version set to 0.16.0
We've passed feature freeze for Shotwell 0.15, so I don't believe we'll be able to get this in for the next release. However, I'll review it shortly and let you know what I think. If/when it's ready, we'll try and land it in 0.16.
-- Jim
--- Bug imported by chaz@yorba.org 2013-11-25 21:54 UTC ---
This bug was previously known as bug 3714 at http://redmine.yorba.org/show_bug.cgi?id=3714
Unknown milestone "unknown in product shotwell. Setting to default milestone for this product, "---". Setting qa contact to the default for this product. This bug either had no qa contact or an invalid one. Resolution set on an open status. Dropping resolution
Version: 0.15.1
Resolution: RESOLVED FIXED