Opened 8 years ago

Closed 7 years ago

#5458 closed defect (fixed)

batchaddmedia does not properly parse the "media:location" header field

Reported by: Tim McIver Owned by:
Priority: minor Milestone:
Component: programming Keywords: small
Cc: simenheg Parent Tickets:

Description

The documentation here: http://mediagoblin.readthedocs.io/en/stable/siteadmin/commandline-upload.html#command-line-batch-uploading states that the path to a media file is given by the "media:location" header field but using this header field name causes a parse error.

Looking at the code here: http://git.savannah.gnu.org/cgit/mediagoblin.git/tree/mediagoblin/gmg_commands/batchaddmedia.py#n111 it seems the code is expecting the header field name to be "location". So, I guess either a code change or a documentation change is needed.

Change History (4)

comment:1 by Ben Sturmfels, 8 years ago

Keywords: small added
Priority: majorminor

comment:2 by simenheg, 7 years ago

Cc: simenheg added

comment:3 by simenheg, 7 years ago

I was bitten by the issue while setting up MediaGoblin for the first time, following the guide at http://mediagoblin.readthedocs.io/en/stable/siteadmin/commandline-upload.html#command-line-batch-uploading.

It would be good to align the documentation and the behavior of the code. I can volunteer to create a patch for it, but I need to know who is right in this case: the documentation or the code?

comment:4 by ayleph, 7 years ago

Resolution: fixed
Status: newclosed

I looked back through the commits, and it appears that media:location was later changed to location but the docs weren't updated. I've updated the docs and pushed to master (0af3ba7) and stable (92cdb1d).

Note: See TracTickets for help on using tickets.