You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by ma...@apache.org on 2021/06/02 21:45:52 UTC
[airavata-django-portal] 01/05: AIRAVATA-3465 Upgrading wagtail to
2.9.3
This is an automated email from the ASF dual-hosted git repository.
machristie pushed a commit to branch airavata-3465
in repository https://gitbox.apache.org/repos/asf/airavata-django-portal.git
commit f4d2599b556f6e77f8a9d60de19ee503c3f6c6bc
Author: Marcus Christie <ma...@apache.org>
AuthorDate: Thu May 27 18:02:36 2021 -0400
AIRAVATA-3465 Upgrading wagtail to 2.9.3
---
django_airavata/settings.py | 1 -
django_airavata/wagtailapps/base/templatetags/navigation_tags.py | 4 ++--
requirements.txt | 4 ++--
3 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/django_airavata/settings.py b/django_airavata/settings.py
index 8888066..16628e1 100644
--- a/django_airavata/settings.py
+++ b/django_airavata/settings.py
@@ -128,7 +128,6 @@ MIDDLEWARE = [
# profile_service_client
'django_airavata.apps.auth.middleware.gateway_groups_middleware',
# Wagtail related middleware
- 'wagtail.core.middleware.SiteMiddleware',
'wagtail.contrib.redirects.middleware.RedirectMiddleware',
]
diff --git a/django_airavata/wagtailapps/base/templatetags/navigation_tags.py b/django_airavata/wagtailapps/base/templatetags/navigation_tags.py
index 1291564..eaa92bc 100644
--- a/django_airavata/wagtailapps/base/templatetags/navigation_tags.py
+++ b/django_airavata/wagtailapps/base/templatetags/navigation_tags.py
@@ -1,6 +1,6 @@
from django import template
from django.conf import settings
-from wagtail.core.models import Page
+from wagtail.core.models import Page, Site
from django_airavata.wagtailapps.base.models import (
Announcements,
@@ -23,7 +23,7 @@ def get_site_root(context):
# This returns a core.Page. The main menu needs to have the site.root_page
# defined else will return an object attribute error ('str' object has no
# attribute 'get_children')
- return context['request'].site.root_page
+ return Site.find_for_request(context['request']).root_page
def has_menu_children(page):
diff --git a/requirements.txt b/requirements.txt
index 1d50ed9..07f1eb9 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,5 +1,5 @@
# Pin these dependencies
-Django>=2.2,<2.3
+Django==2.2.23
requests==2.13.0
requests-oauthlib==0.7.0
thrift==0.10.0
@@ -7,7 +7,7 @@ thrift_connector==0.24
djangorestframework==3.10.3
django-webpack-loader==0.6.0
-wagtail>=2.7,<2.8
+wagtail==2.9.3
wagtailfontawesome==1.2.1
jupyter==1.0.0