Opened 9 years ago

Closed 4 years ago

#1018 closed defect (fixed)

atom feed fails when untitled media is included

Reported by: ayleph Owned by:
Priority: major Milestone:
Component: programming Keywords: feed, atom, title, bitesized
Cc: Parent Tickets:


Trying to view an atom feed which includes media without a title returns a server error. The log output is below.

Error - <type 'exceptions.ValueError'>: title is required
File '/path/to/mediagoblin/lib/python2.7/site-packages/Paste-', line 144 in __call__
  app_iter = self.application(environ, sr_checker)
File '/path/to/mediagoblin/lib/python2.7/site-packages/Paste-', line 203 in __call__
  return app(environ, start_response)
File '/path/to/mediagoblin/mediagoblin/', line 268 in __call__
  return self.call_backend(environ, start_response)
File '/path/to/mediagoblin/lib/python2.7/site-packages/Werkzeug-0.9.6-py2.7.egg/werkzeug/', line 588 in __call__
  return, start_response)
File '/path/to/mediagoblin/mediagoblin/', line 245 in call_backend
  response = controller(request)
File '/path/to/mediagoblin/mediagoblin/user_pages/', line 542 in atom_feed
  'type': 'text/html'}])
File '/path/to/mediagoblin/lib/python2.7/site-packages/Werkzeug-0.9.6-py2.7.egg/werkzeug/contrib/', line 144 in add
  self.entries.append(FeedEntry(*args, **kwargs))
File '/path/to/mediagoblin/lib/python2.7/site-packages/Werkzeug-0.9.6-py2.7.egg/werkzeug/contrib/', line 294 in __init__
  raise ValueError('title is required')
ValueError: title is required

So how do you get media without a title? Upload media, edit it, clear the title, and save changes. Maybe saving media with no title should not be allowed.

Change History (3)

comment:1 by Ben Sturmfels, 8 years ago

Keywords: bitesized added

Marking as "bitesized" since this is self-contained and should be fairly straightforward to fix. The feed should accommodate whatever is in the database as the title - we can't necessarily rely on input validation.

comment:2 by jsandoval, 7 years ago

Owner: set to jsandoval
Status: newin_progress

comment:3 by Ben Sturmfels, 4 years ago

Owner: jsandoval removed
Resolution: fixed
Status: in_progressclosed
Note: See TracTickets for help on using tickets.