Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
2d0fc911
Commit
2d0fc911
authored
Jul 27, 2017
by
Matt Tuchfarber
Committed by
GitHub
Jul 27, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #15668 from edx/tuchfarber/WL-1140
Make HTTP 500 error pages site-aware
parents
5fca0521
827c703d
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
28 additions
and
13 deletions
+28
-13
lms/static/sass/multicourse/_error-pages.scss
+1
-0
lms/templates/courseware/courseware-error.html
+6
-2
lms/templates/courseware/error-message.html
+6
-3
lms/templates/module-error.html
+7
-3
lms/templates/static_templates/server-down.html
+3
-2
lms/templates/static_templates/server-overloaded.html
+3
-2
openedx/core/djangoapps/external_auth/views.py
+2
-1
No files found.
lms/static/sass/multicourse/_error-pages.scss
View file @
2d0fc911
...
...
@@ -6,6 +6,7 @@ section.outside-app {
h1
{
@extend
h2
;
margin-bottom
:
(
$baseline
*
2
);
text-align
:
center
;
}
p
,
ul
,
form
{
...
...
lms/templates/courseware/courseware-error.html
View file @
2d0fc911
...
...
@@ -3,6 +3,10 @@
<
%
namespace
name=
'static'
file=
'../static_content.html'
/>
<
%
block
name=
"bodyclass"
>
courseware
</
%
block>
<
%
block
name=
"pagetitle"
>
${_("Courseware")}
</
%
block>
<
%!
from
django
.
utils
.
translation
import
ugettext
as
_
from
openedx
.
core
.
djangolib
.
markup
import
HTML
,
Text
%
>
<
%
block
name=
"headextra"
>
<
%
static:css
group=
'style-course-vendor'
/>
...
...
@@ -15,13 +19,13 @@
<section
class=
"outside-app"
>
<h1>
${_('There has been an error on the {platform_name} servers').format(
platform_name=u'
<span
class=
"edx"
>
{}
</span>
'.format(s
ettings.PLATFORM_NAME
)
platform_name=u'
<span
class=
"edx"
>
{}
</span>
'.format(s
tatic.get_platform_name()
)
)}
</h1>
<p>
${_("We're sorry, this module is temporarily unavailable. Our staff is working to fix "
"it as soon as possible. Please email us at {tech_support_email} to report any problems or downtime.").format(
tech_support_email=u'
<a
href=
\"mailto:{0}\"
>
{0}
</a>
'.format(s
ettings.TECH_SUPPORT_EMAIL
)
tech_support_email=u'
<a
href=
\"mailto:{0}\"
>
{0}
</a>
'.format(s
tatic.get_tech_support_email_address()
)
)}
</p>
</section>
...
...
lms/templates/courseware/error-message.html
View file @
2d0fc911
## mako
<
%!
from
django
.
utils
.
translation
import
ugettext
as
_
%
>
<
%
namespace
name=
'static'
file=
'../static_content.html'
/>
<
%!
from
django
.
utils
.
translation
import
ugettext
as
_
from
openedx
.
core
.
djangolib
.
markup
import
HTML
,
Text
%
>
<
%
tech_support_email=
'<a href=\"mailto:{tech_support_email}\">{tech_support_email}</a>'
.
format
(
tech_support_email=
s
ettings.TECH_SUPPORT_EMAIL
)
tech_support_email=
'<a href=\"mailto:{tech_support_email}\">{tech_support_email}</a>'
.
format
(
tech_support_email=
s
tatic.get_tech_support_email_address()
)
%
>
<p>
${_("We're sorry, this module is temporarily unavailable. Our staff is working to fix it as soon as possible. Please email us at {tech_support_email} to report any problems or downtime.").format(tech_support_email=tech_support_email)}
</p>
lms/templates/module-error.html
View file @
2d0fc911
<
%!
from
django
.
utils
.
translation
import
ugettext
as
_
%
>
<
%!
from
django
.
utils
.
translation
import
ugettext
as
_
from
openedx
.
core
.
djangolib
.
markup
import
HTML
,
Text
%
>
<
%
namespace
name=
'static'
file=
'../static_content.html'
/>
<section
class=
"outside-app"
>
<h1>
${_("There has been an error on the {platform_name} servers").format(
platform_name=u"
<em>
{}
</em>
".format(s
ettings.PLATFORM_NAME
)
platform_name=u"
<em>
{}
</em>
".format(s
tatic.get_platform_name()
)
)}
</h1>
<p>
${_("We're sorry, this module is temporarily unavailable. Our staff is working "
"to fix it as soon as possible. Please email us at {tech_support_email} to "
"report any problems or downtime.").format(
tech_support_email=u"
<a
href=
\"mailto:{0}\"
>
{0}
</a>
".format(s
ettings.TECH_SUPPORT_EMAIL
)
tech_support_email=u"
<a
href=
\"mailto:{0}\"
>
{0}
</a>
".format(s
tatic.get_tech_support_email_address()
)
)}
</p>
...
...
lms/templates/static_templates/server-down.html
View file @
2d0fc911
...
...
@@ -4,18 +4,19 @@ from django.utils.translation import ugettext as _
from
openedx
.
core
.
djangolib
.
markup
import
HTML
,
Text
%
>
<
%
inherit
file=
"../main.html"
/>
<
%
namespace
name=
'static'
file=
'../static_content.html'
/>
<main
id=
"main"
aria-label=
"Content"
tabindex=
"-1"
>
<section
class=
"outside-app"
>
<h1>
${Text(_("Currently the {platform_name} servers are down")).format(
platform_name=HTML(u"
<em>
{}
</em>
").format(Text(s
ettings.PLATFORM_NAME
))
platform_name=HTML(u"
<em>
{}
</em>
").format(Text(s
tatic.get_platform_name()
))
)}
</h1>
<p>
${Text(_("Our staff is currently working to get the site back up as soon as possible. "
"Please email us at {tech_support_email} to report any problems or downtime.")).format(
tech_support_email=HTML('
<a
href=
"mailto:{0}"
>
{0}
</a>
').format(Text(s
ettings.TECH_SUPPORT_EMAIL
))
tech_support_email=HTML('
<a
href=
"mailto:{0}"
>
{0}
</a>
').format(Text(s
tatic.get_tech_support_email_address()
))
)}
</p>
</section>
</main>
lms/templates/static_templates/server-overloaded.html
View file @
2d0fc911
...
...
@@ -4,18 +4,19 @@ from django.utils.translation import ugettext as _
from
openedx
.
core
.
djangolib
.
markup
import
HTML
,
Text
%
>
<
%
inherit
file=
"../main.html"
/>
<
%
namespace
name=
'static'
file=
'../static_content.html'
/>
<main
id=
"main"
aria-label=
"Content"
tabindex=
"-1"
>
<section
class=
"outside-app"
>
<h1>
${Text(_("Currently the {platform_name} servers are overloaded")).format(
platform_name=HTML("
<em>
{}
</em>
").format(platform_name=Text(s
ettings.PLATFORM_NAME
))
platform_name=HTML("
<em>
{}
</em>
").format(platform_name=Text(s
tatic.get_platform_name()
))
)}
</h1>
<p>
${Text(_("Our staff is currently working to get the site back up as soon as possible. "
"Please email us at {tech_support_email} to report any problems or downtime.")).format(
tech_support_email=HTML('
<a
href=
"mailto:{0}"
>
{0}
</a>
').format(tech_support_email=Text(s
ettings.TECH_SUPPORT_EMAIL
))
tech_support_email=HTML('
<a
href=
"mailto:{0}"
>
{0}
</a>
').format(tech_support_email=Text(s
tatic.get_tech_support_email_address()
))
)}
</p>
</section>
...
...
openedx/core/djangoapps/external_auth/views.py
View file @
2d0fc911
...
...
@@ -36,6 +36,7 @@ import student.views
from
edxmako.shortcuts
import
render_to_response
,
render_to_string
from
openedx.core.djangoapps.external_auth.djangostore
import
DjangoOpenIDStore
from
openedx.core.djangoapps.external_auth.models
import
ExternalAuthMap
from
openedx.core.djangoapps.site_configuration.helpers
import
get_value
from
student.helpers
import
get_next_url_for_login_page
from
student.models
import
UserProfile
from
xmodule.modulestore.django
import
modulestore
...
...
@@ -171,7 +172,7 @@ def _external_login_or_signup(request,
"an external login like WebAuth or Shibboleth. "
"Please contact {tech_support_email} for support."
)
.
format
(
tech_support_email
=
settings
.
TECH_SUPPORT_EMAIL
,
tech_support_email
=
get_value
(
'email_from_address'
,
settings
.
TECH_SUPPORT_EMAIL
)
,
)
return
default_render_failure
(
request
,
failure_msg
)
except
User
.
DoesNotExist
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment