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
57f9701a
Commit
57f9701a
authored
Sep 16, 2014
by
Calen Pennington
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clean up exception definitions
parent
4b068683
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
6 deletions
+5
-6
common/lib/xmodule/xmodule/modulestore/draft_and_published.py
+1
-1
common/lib/xmodule/xmodule/modulestore/exceptions.py
+4
-5
No files found.
common/lib/xmodule/xmodule/modulestore/draft_and_published.py
View file @
57f9701a
...
...
@@ -113,7 +113,7 @@ class ModuleStoreDraftAndPublished(BranchSettingMixin):
raise
NotImplementedError
class
UnsupportedRevisionError
(
ValueError
):
class
UnsupportedRevisionError
(
ValueError
):
"""
This error is raised if a method is called with an unsupported revision parameter.
"""
...
...
common/lib/xmodule/xmodule/modulestore/exceptions.py
View file @
57f9701a
...
...
@@ -74,7 +74,9 @@ class DuplicateCourseError(Exception):
"""
existing_entry will have the who, when, and other properties of the existing entry
"""
super
(
DuplicateCourseError
,
self
)
.
__init__
()
super
(
DuplicateCourseError
,
self
)
.
__init__
(
u'Cannot create course {}, which duplicates {}'
.
format
(
course_id
,
existing_entry
)
)
self
.
course_id
=
course_id
self
.
existing_entry
=
existing_entry
...
...
@@ -84,9 +86,6 @@ class InvalidBranchSetting(Exception):
Raised when the process' branch setting did not match the required setting for the attempted operation on a store.
"""
def
__init__
(
self
,
expected_setting
,
actual_setting
):
super
(
InvalidBranchSetting
,
self
)
.
__init__
()
super
(
InvalidBranchSetting
,
self
)
.
__init__
(
u"Invalid branch: expected {} but got {}"
.
format
(
expected_setting
,
actual_setting
)
)
self
.
expected_setting
=
expected_setting
self
.
actual_setting
=
actual_setting
def
__unicode__
(
self
,
*
args
,
**
kwargs
):
return
u"Invalid branch: expected {} but got {}"
.
format
(
self
.
expected_setting
,
self
.
actual_setting
)
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