* [layerindex-web][PATCH 1/3] views: fix regression in publish email sending code
2018-05-04 11:55 [layerindex-web][PATCH 0/3] Fixes for some recent changes Paul Eggleton
@ 2018-05-04 11:55 ` Paul Eggleton
2018-05-04 11:55 ` [layerindex-web][PATCH 2/3] requirements.txt: fix some conflicting requirements Paul Eggleton
2018-05-04 11:55 ` [layerindex-web][PATCH 3/3] detail: Fix layer description not wrapping properly Paul Eggleton
2 siblings, 0 replies; 4+ messages in thread
From: Paul Eggleton @ 2018-05-04 11:55 UTC (permalink / raw)
To: yocto
In e902b67bccddf34d8bbd65ad6c81d078e945ebb8 I missed a couple of Context
usages in the layer publish view and the result was that it broke
publishing a layer (and apparently I didn't run a final test on that,
shame on me).
Thanks to Yi Zhao <yi.zhao@windriver.com> for pointing this out.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
---
layerindex/views.py | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/layerindex/views.py b/layerindex/views.py
index c84982ae..bc3cddfa 100644
--- a/layerindex/views.py
+++ b/layerindex/views.py
@@ -20,7 +20,6 @@ from django.db import transaction
from django.contrib.auth.models import User, Permission
from django.db.models import Q, Count, Sum
from django.template.loader import get_template
-from django.template import Context
from django.utils.decorators import method_decorator
from django.contrib.auth.decorators import login_required
from django.contrib import messages
@@ -277,19 +276,19 @@ def publish_view(request, name):
break
# create subject from subject template
- d = Context({
+ d = {
'layer_name': layeritem.name,
'site_name': request.META['HTTP_HOST'],
- })
+ }
subject = subjecttext.render(d).rstrip()
#create body from body template
- d = Context({
+ d = {
'maintainers': maintainer_names,
'layer_name': layeritem.name,
'layer_url': layer_url,
'help_contact': help_contact,
- })
+ }
body = bodytext.render(d)
tasks.send_email.apply_async((subject, body, from_email, [m.email for m in maintainers]))
--
2.14.3
^ permalink raw reply related [flat|nested] 4+ messages in thread* [layerindex-web][PATCH 2/3] requirements.txt: fix some conflicting requirements
2018-05-04 11:55 [layerindex-web][PATCH 0/3] Fixes for some recent changes Paul Eggleton
2018-05-04 11:55 ` [layerindex-web][PATCH 1/3] views: fix regression in publish email sending code Paul Eggleton
@ 2018-05-04 11:55 ` Paul Eggleton
2018-05-04 11:55 ` [layerindex-web][PATCH 3/3] detail: Fix layer description not wrapping properly Paul Eggleton
2 siblings, 0 replies; 4+ messages in thread
From: Paul Eggleton @ 2018-05-04 11:55 UTC (permalink / raw)
To: yocto
pip (strangely only in the python 2 version when I test it here) reports
that some of the versions in requirements.txt were incompatible:
django-nvd3 0.9.7 has requirement python-nvd3==0.14.2, but you'll have
python-nvd3 0.15.0 which is incompatible.
django-registration 2.4.1 has requirement confusable-homoglyphs~=3.0,
but you'll have confusable-homoglyphs 2.0.2 which is incompatible.
python-nvd3 0.14.2 has requirement python-slugify==1.1.4, but you'll
have python-slugify 1.2.5 which is incompatible.
I'm not particularly keen on downgrading these but it seems like we
don't have much choice. Luckily looking over the changelogs it doesn't
seem like that will cause us any problems though.
Thanks to Yi Zhao <yi.zhao@windriver.com> for pointing this out.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
---
requirements.txt | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/requirements.txt b/requirements.txt
index 604c653e..5ca7cf6e 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -2,7 +2,7 @@ amqp==2.2.2
anyjson==0.3.3
billiard==3.5.0.3
celery==4.1.0
-confusable-homoglyphs==2.0.2
+confusable-homoglyphs==3.0.0
Django>1.11.0,<1.12
django-cors-headers==1.1.0
django-nvd3==0.9.7
@@ -19,8 +19,8 @@ kombu==4.1.0
MarkupSafe==1.0
mysqlclient==1.3.12
Pillow==5.1.0
-python-nvd3==0.15.0
-python-slugify==1.2.5
+python-nvd3==0.14.2
+python-slugify==1.1.4
pytz==2018.4
six==1.11.0
smmap==0.9.0
--
2.14.3
^ permalink raw reply related [flat|nested] 4+ messages in thread