mozilla/zamboni — pull request #1480 by ngokevin (2013-12-02 22:39:29+00:00)
Title: fix deleting apps that have content ratings (bug 945466)

Was trying to set IARC storefront data (which fetches the app) after the app was deleted. No likey.

DoesNotExist: Addon matching query does not exist.

Stacktrace (most recent call last):

File "django/core/handlers/base.py", line 111, in get_response
response = callback(request, *callback_args, **callback_kwargs)
File "newrelic/hooks/framework_django.py", line 485, in wrapper
return wrapped(*args, **kwargs)
File "amo/decorators.py", line 157, in wrapper
return f(*args, **kw)
File "amo/decorators.py", line 149, in wrapper
return f(*args, **kw)
File "addons/decorators.py", line 33, in wrapper
return f(request, addon, *args, **kw)
File "amo/decorators.py", line 32, in wrapper
return func(request, *args, **kw)
File "mkt/developers/decorators.py", line 49, in wrapper
return fun()
File "mkt/developers/decorators.py", line 28, in
*args, **kw)
File "amo/decorators.py", line 51, in wrapper
return f(request, *args, **kw)
File "mkt/developers/views.py", line 158, in delete
addon.delete(msg='Removed via devhub', reason=reason)
File "django/db/transaction.py", line 224, in inner
return func(*args, **kwargs)
File "addons/models.py", line 453, in delete
self.set_iarc_storefront_data(disable=True)
File "mkt/webapps/models.py", line 1172, in set_iarc_storefront_data
delocalized_self = Addon.objects.get(pk=self.pk)
File "django/db/models/manager.py", line 131, in get
return self.get_query_set().get(*args, **kwargs)
File "django/db/models/query.py", line 366, in get
% self.model._meta.object_name)