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
744652d7
Commit
744652d7
authored
Nov 15, 2012
by
Calen Pennington
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Start of changes for xmodule debugger app
parent
48720497
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
22 additions
and
15 deletions
+22
-15
common/lib/xmodule/setup.py
+5
-0
common/lib/xmodule/xmodule/mako_module.py
+1
-1
common/lib/xmodule/xmodule/seq_module.py
+5
-5
common/lib/xmodule/xmodule/vertical_module.py
+3
-3
common/lib/xmodule/xmodule/xml_module.py
+2
-2
common/lib/xmodule/xmodule/xmodule.py
+6
-4
No files found.
common/lib/xmodule/setup.py
View file @
744652d7
...
@@ -10,6 +10,8 @@ setup(
...
@@ -10,6 +10,8 @@ setup(
},
},
requires
=
[
requires
=
[
'capa'
,
'capa'
,
# TODO: This isn't actually forcing an install, for some reason
'fs (>= 0.4.0)'
,
],
],
# See http://guide.python-distribute.org/creation.html#entry-points
# See http://guide.python-distribute.org/creation.html#entry-points
...
@@ -35,6 +37,9 @@ setup(
...
@@ -35,6 +37,9 @@ setup(
"videodev = xmodule.backcompat_module:TranslateCustomTagDescriptor"
,
"videodev = xmodule.backcompat_module:TranslateCustomTagDescriptor"
,
"videosequence = xmodule.seq_module:SequenceDescriptor"
,
"videosequence = xmodule.seq_module:SequenceDescriptor"
,
"discussion = xmodule.discussion_module:DiscussionDescriptor"
,
"discussion = xmodule.discussion_module:DiscussionDescriptor"
,
],
'xmodule.v2'
:
[
'vertical = xmodule.vertical_module:VerticalModule'
,
]
]
}
}
)
)
common/lib/xmodule/xmodule/mako_module.py
View file @
744652d7
from
x_
module
import
XModuleDescriptor
,
DescriptorSystem
from
.x
module
import
XModuleDescriptor
,
DescriptorSystem
import
logging
import
logging
...
...
common/lib/xmodule/xmodule/seq_module.py
View file @
744652d7
...
@@ -3,11 +3,11 @@ import logging
...
@@ -3,11 +3,11 @@ import logging
from
lxml
import
etree
from
lxml
import
etree
from
xmodule
.mako_module
import
MakoModuleDescriptor
from
.mako_module
import
MakoModuleDescriptor
from
xmodule
.xml_module
import
XmlDescriptor
from
.xml_module
import
XmlDescriptor
from
xmodule.x_
module
import
XModule
from
.x
module
import
XModule
from
xmodule
.progress
import
Progress
from
.progress
import
Progress
from
xmodule
.exceptions
import
NotFoundError
from
.exceptions
import
NotFoundError
from
pkg_resources
import
resource_string
from
pkg_resources
import
resource_string
log
=
logging
.
getLogger
(
"mitx.common.lib.seq_module"
)
log
=
logging
.
getLogger
(
"mitx.common.lib.seq_module"
)
...
...
common/lib/xmodule/xmodule/vertical_module.py
View file @
744652d7
from
xmodule.x_
module
import
XModule
from
.x
module
import
XModule
from
xmodule
.seq_module
import
SequenceDescriptor
from
.seq_module
import
SequenceDescriptor
from
xmodule
.progress
import
Progress
from
.progress
import
Progress
# HACK: This shouldn't be hard-coded to two types
# HACK: This shouldn't be hard-coded to two types
# OBSOLETE: This obsoletes 'type'
# OBSOLETE: This obsoletes 'type'
...
...
common/lib/xmodule/xmodule/xml_module.py
View file @
744652d7
from
xmodule.x_
module
import
(
XModuleDescriptor
,
policy_key
)
from
.x
module
import
(
XModuleDescriptor
,
policy_key
)
from
xmodule
.modulestore
import
Location
from
.modulestore
import
Location
from
lxml
import
etree
from
lxml
import
etree
import
json
import
json
import
copy
import
copy
...
...
common/lib/xmodule/xmodule/x
_
module.py
→
common/lib/xmodule/xmodule/xmodule.py
View file @
744652d7
...
@@ -9,10 +9,10 @@ from pprint import pprint
...
@@ -9,10 +9,10 @@ from pprint import pprint
from
collections
import
namedtuple
from
collections
import
namedtuple
from
pkg_resources
import
resource_listdir
,
resource_string
,
resource_isdir
from
pkg_resources
import
resource_listdir
,
resource_string
,
resource_isdir
from
xmodule
.modulestore
import
Location
from
.modulestore
import
Location
from
xmodule
.timeparse
import
parse_time
from
.timeparse
import
parse_time
from
xmodule
.contentstore.content
import
StaticContent
,
XASSET_SRCREF_PREFIX
from
.contentstore.content
import
StaticContent
,
XASSET_SRCREF_PREFIX
log
=
logging
.
getLogger
(
'mitx.'
+
__name__
)
log
=
logging
.
getLogger
(
'mitx.'
+
__name__
)
...
@@ -133,7 +133,7 @@ class HTMLSnippet(object):
...
@@ -133,7 +133,7 @@ class HTMLSnippet(object):
.
format
(
self
.
__class__
))
.
format
(
self
.
__class__
))
class
XModule
(
HTMLSnippet
):
class
XModule
(
Plugin
,
HTMLSnippet
):
''' Implements a generic learning module.
''' Implements a generic learning module.
Subclasses must at a minimum provide a definition for get_html in order
Subclasses must at a minimum provide a definition for get_html in order
...
@@ -150,6 +150,8 @@ class XModule(HTMLSnippet):
...
@@ -150,6 +150,8 @@ class XModule(HTMLSnippet):
# in the module
# in the module
icon_class
=
'other'
icon_class
=
'other'
entry_point
=
"xmodule.v2"
def
__init__
(
self
,
system
,
location
,
definition
,
descriptor
,
def
__init__
(
self
,
system
,
location
,
definition
,
descriptor
,
instance_state
=
None
,
shared_state
=
None
,
**
kwargs
):
instance_state
=
None
,
shared_state
=
None
,
**
kwargs
):
'''
'''
...
...
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