Skip to content
This repository was archived by the owner on Mar 15, 2018. It is now read-only.

Commit 4ff5717

Browse files
committed
serve yulelog .zip (bug 855579)
1 parent 5c3123a commit 4ff5717

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed
7.41 KB
Binary file not shown.

mkt/site/views.py

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66

77
from django.conf import settings
88
from django.core.exceptions import PermissionDenied
9+
from django.core.files.storage import default_storage as storage
910
from django.http import (HttpResponse, HttpResponseNotFound,
1011
HttpResponseServerError)
1112
from django.template import RequestContext
@@ -21,7 +22,7 @@
2122

2223
from amo.context_processors import get_collect_timings
2324
from amo.decorators import post_required
24-
from amo.helpers import media
25+
from amo.helpers import absolutify, media
2526
from amo.urlresolvers import reverse
2627
from amo.utils import urlparams
2728

@@ -107,6 +108,12 @@ def _inner_view(request):
107108

108109

109110
def minifest(request):
111+
yulelog_fn = 'yulelog_2013.0328.zip'
112+
yulelog_path = os.path.join(settings.MEDIA_ROOT, 'packaged-apps',
113+
yulelog_fn)
114+
yulelog_url = absolutify('%spackaged-apps/%s' %
115+
(settings.MEDIA_URL, yulelog_fn))
116+
110117
data = {
111118
'description': 'The Firefox Marketplace',
112119
'developer': {
@@ -118,8 +125,8 @@ def minifest(request):
118125
},
119126
'name': getattr(settings, 'WEBAPP_MANIFEST_NAME',
120127
'Firefox Marketplace'),
121-
#'size': 0,
122-
'package_path': '', # TODO: Fill in.
128+
'size': storage.size(yulelog_path),
129+
'package_path': yulelog_url,
123130
#'release_notes': '',
124131
'version': '0.0.1',
125132
}

0 commit comments

Comments
 (0)