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
55de42d1
Commit
55de42d1
authored
Nov 09, 2014
by
stv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix PEP8: E122 continuation line missing
indentation or outdented
parent
dff5772c
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
35 additions
and
39 deletions
+35
-39
common/djangoapps/static_replace/management/commands/clear_collectstatic_cache.py
+1
-2
common/djangoapps/student/management/commands/6002exportusers.py
+2
-3
common/djangoapps/student/management/commands/6002importusers.py
+2
-3
common/djangoapps/student/management/commands/assigngroups.py
+10
-10
common/djangoapps/student/management/commands/emaillist.py
+1
-2
common/djangoapps/student/management/commands/sync_user_info.py
+1
-4
common/djangoapps/student/management/commands/userinfo.py
+2
-3
common/lib/xmodule/xmodule/annotatable_module.py
+4
-3
common/lib/xmodule/xmodule/mako_module.py
+6
-3
docs/shared/conf.py
+6
-6
No files found.
common/djangoapps/static_replace/management/commands/clear_collectstatic_cache.py
View file @
55de42d1
...
@@ -7,8 +7,7 @@ from django.core.cache import get_cache
...
@@ -7,8 +7,7 @@ from django.core.cache import get_cache
class
Command
(
NoArgsCommand
):
class
Command
(
NoArgsCommand
):
help
=
\
help
=
'Import the specified data directory into the default ModuleStore'
'''Import the specified data directory into the default ModuleStore'''
def
handle_noargs
(
self
,
**
options
):
def
handle_noargs
(
self
,
**
options
):
staticfiles_cache
=
get_cache
(
'staticfiles'
)
staticfiles_cache
=
get_cache
(
'staticfiles'
)
...
...
common/djangoapps/student/management/commands/6002exportusers.py
View file @
55de42d1
...
@@ -18,14 +18,13 @@ from student.models import UserProfile
...
@@ -18,14 +18,13 @@ from student.models import UserProfile
class
Command
(
BaseCommand
):
class
Command
(
BaseCommand
):
help
=
\
help
=
"""Exports all users and user profiles.
'''Exports all users and user profiles.
Caveat: Should be looked over before any run
Caveat: Should be looked over before any run
for schema changes.
for schema changes.
Current version grabs user_keys from
Current version grabs user_keys from
django.contrib.auth.models.User and up_keys
django.contrib.auth.models.User and up_keys
from student.userprofile.
'''
from student.userprofile.
"""
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
users
=
list
(
User
.
objects
.
all
())
users
=
list
(
User
.
objects
.
all
())
...
...
common/djangoapps/student/management/commands/6002importusers.py
View file @
55de42d1
...
@@ -39,14 +39,13 @@ def import_user(u):
...
@@ -39,14 +39,13 @@ def import_user(u):
class
Command
(
BaseCommand
):
class
Command
(
BaseCommand
):
help
=
\
help
=
"""Exports all users and user profiles.
'''Exports all users and user profiles.
Caveat: Should be looked over before any run
Caveat: Should be looked over before any run
for schema changes.
for schema changes.
Current version grabs user_keys from
Current version grabs user_keys from
django.contrib.auth.models.User and up_keys
django.contrib.auth.models.User and up_keys
from student.userprofile.
'''
from student.userprofile.
"""
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
extracted
=
json
.
load
(
open
(
'transfer_users.txt'
))
extracted
=
json
.
load
(
open
(
'transfer_users.txt'
))
...
...
common/djangoapps/student/management/commands/assigngroups.py
View file @
55de42d1
...
@@ -6,6 +6,7 @@ from student.models import UserTestGroup
...
@@ -6,6 +6,7 @@ from student.models import UserTestGroup
import
random
import
random
import
sys
import
sys
import
datetime
import
datetime
from
textwrap
import
dedent
import
json
import
json
from
pytz
import
UTC
from
pytz
import
UTC
...
@@ -25,16 +26,15 @@ def group_from_value(groups, v):
...
@@ -25,16 +26,15 @@ def group_from_value(groups, v):
class
Command
(
BaseCommand
):
class
Command
(
BaseCommand
):
help
=
\
help
=
dedent
(
"""
\
''' Assign users to test groups. Takes a list
Assign users to test groups. Takes a list of groups:
of groups:
a:0.3,b:0.4,c:0.3 file.txt "Testing something"
a:0.3,b:0.4,c:0.3 file.txt "Testing something"
Will assign each user to group a, b, or c with
Will assign each user to group a, b, or c with
probability 0.3, 0.4, 0.3. Probabilities must
probability 0.3, 0.4, 0.3. Probabilities must
add up to 1.
add up to 1.
Will log what happened to file.txt.
Will log what happened to file.txt.
"""
)
'''
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
if
len
(
args
)
!=
3
:
if
len
(
args
)
!=
3
:
...
...
common/djangoapps/student/management/commands/emaillist.py
View file @
55de42d1
...
@@ -3,8 +3,7 @@ from django.contrib.auth.models import User
...
@@ -3,8 +3,7 @@ from django.contrib.auth.models import User
class
Command
(
BaseCommand
):
class
Command
(
BaseCommand
):
help
=
\
help
=
'Extract an e-mail list of all active students.'
''' Extract an e-mail list of all active students. '''
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
#text = open(args[0]).read()
#text = open(args[0]).read()
...
...
common/djangoapps/student/management/commands/sync_user_info.py
View file @
55de42d1
...
@@ -8,10 +8,7 @@ import lms.lib.comment_client as cc
...
@@ -8,10 +8,7 @@ import lms.lib.comment_client as cc
class
Command
(
BaseCommand
):
class
Command
(
BaseCommand
):
help
=
\
help
=
'Sync all user ids, usernames, and emails to the discussion service'
'''
Sync all user ids, usernames, and emails to the discussion
service'''
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
for
user
in
User
.
objects
.
all
()
.
iterator
():
for
user
in
User
.
objects
.
all
()
.
iterator
():
...
...
common/djangoapps/student/management/commands/userinfo.py
View file @
55de42d1
...
@@ -7,9 +7,8 @@ from student.models import UserProfile
...
@@ -7,9 +7,8 @@ from student.models import UserProfile
class
Command
(
BaseCommand
):
class
Command
(
BaseCommand
):
help
=
\
help
=
"""Extract full user information into a JSON file.
''' Extract full user information into a JSON file.
Pass a single filename."""
Pass a single filename.'''
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
f
=
open
(
args
[
0
],
'w'
)
f
=
open
(
args
[
0
],
'w'
)
...
...
common/lib/xmodule/xmodule/annotatable_module.py
View file @
55de42d1
...
@@ -15,9 +15,10 @@ _ = lambda text: text
...
@@ -15,9 +15,10 @@ _ = lambda text: text
class
AnnotatableFields
(
object
):
class
AnnotatableFields
(
object
):
data
=
String
(
help
=
_
(
"XML data for the annotation"
),
scope
=
Scope
.
content
,
data
=
String
(
default
=
textwrap
.
dedent
(
help
=
_
(
"XML data for the annotation"
),
"""
\
scope
=
Scope
.
content
,
default
=
textwrap
.
dedent
(
"""
<annotatable>
<annotatable>
<instructions>
<instructions>
<p>Enter your (optional) instructions for the exercise in HTML format.</p>
<p>Enter your (optional) instructions for the exercise in HTML format.</p>
...
...
common/lib/xmodule/xmodule/mako_module.py
View file @
55de42d1
...
@@ -23,9 +23,12 @@ class MakoModuleDescriptor(XModuleDescriptor):
...
@@ -23,9 +23,12 @@ class MakoModuleDescriptor(XModuleDescriptor):
def
__init__
(
self
,
*
args
,
**
kwargs
):
def
__init__
(
self
,
*
args
,
**
kwargs
):
super
(
MakoModuleDescriptor
,
self
)
.
__init__
(
*
args
,
**
kwargs
)
super
(
MakoModuleDescriptor
,
self
)
.
__init__
(
*
args
,
**
kwargs
)
if
getattr
(
self
.
runtime
,
'render_template'
,
None
)
is
None
:
if
getattr
(
self
.
runtime
,
'render_template'
,
None
)
is
None
:
raise
TypeError
(
'{runtime} must have a render_template function'
raise
TypeError
(
' in order to use a MakoDescriptor'
.
format
(
'{runtime} must have a render_template function'
runtime
=
self
.
runtime
))
' in order to use a MakoDescriptor'
.
format
(
runtime
=
self
.
runtime
,
)
)
def
get_context
(
self
):
def
get_context
(
self
):
"""
"""
...
...
docs/shared/conf.py
View file @
55de42d1
...
@@ -196,14 +196,14 @@ htmlhelp_basename = 'edxdoc'
...
@@ -196,14 +196,14 @@ htmlhelp_basename = 'edxdoc'
# -- Options for LaTeX output --------------------------------------------------
# -- Options for LaTeX output --------------------------------------------------
latex_elements
=
{
latex_elements
=
{
# The paper size ('letterpaper' or 'a4paper').
# The paper size ('letterpaper' or 'a4paper').
#'papersize': 'letterpaper',
#'papersize': 'letterpaper',
# The font size ('10pt', '11pt' or '12pt').
# The font size ('10pt', '11pt' or '12pt').
#'pointsize': '10pt',
#'pointsize': '10pt',
# Additional stuff for the LaTeX preamble.
# Additional stuff for the LaTeX preamble.
#'preamble': '',
#'preamble': '',
}
}
# Grouping the document tree into LaTeX files. List of tuples
# Grouping the document tree into LaTeX files. List of tuples
...
...
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