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
57909ce1
Commit
57909ce1
authored
Jun 21, 2013
by
Ned Batchelder
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix all W0602, global used but no assignment done.
parent
75b39012
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
0 additions
and
11 deletions
+0
-11
common/djangoapps/student/management/commands/massemailtxt.py
+0
-1
common/lib/xmodule/xmodule/contentstore/django.py
+0
-2
common/lib/xmodule/xmodule/modulestore/django.py
+0
-2
lms/djangoapps/django_comment_client/utils.py
+0
-6
No files found.
common/djangoapps/student/management/commands/massemailtxt.py
View file @
57909ce1
...
@@ -37,7 +37,6 @@ rate -- messages per second
...
@@ -37,7 +37,6 @@ rate -- messages per second
self
.
log_file
.
write
(
datetime
.
datetime
.
utcnow
()
.
isoformat
()
+
' -- '
+
text
+
'
\n
'
)
self
.
log_file
.
write
(
datetime
.
datetime
.
utcnow
()
.
isoformat
()
+
' -- '
+
text
+
'
\n
'
)
def
handle
(
self
,
*
args
,
**
options
):
def
handle
(
self
,
*
args
,
**
options
):
global
log_file
(
user_file
,
message_base
,
logfilename
,
ratestr
)
=
args
(
user_file
,
message_base
,
logfilename
,
ratestr
)
=
args
users
=
[
u
.
strip
()
for
u
in
open
(
user_file
)
.
readlines
()]
users
=
[
u
.
strip
()
for
u
in
open
(
user_file
)
.
readlines
()]
...
...
common/lib/xmodule/xmodule/contentstore/django.py
View file @
57909ce1
...
@@ -18,8 +18,6 @@ def load_function(path):
...
@@ -18,8 +18,6 @@ def load_function(path):
def
contentstore
(
name
=
'default'
):
def
contentstore
(
name
=
'default'
):
global
_CONTENTSTORE
if
name
not
in
_CONTENTSTORE
:
if
name
not
in
_CONTENTSTORE
:
class_
=
load_function
(
settings
.
CONTENTSTORE
[
'ENGINE'
])
class_
=
load_function
(
settings
.
CONTENTSTORE
[
'ENGINE'
])
options
=
{}
options
=
{}
...
...
common/lib/xmodule/xmodule/modulestore/django.py
View file @
57909ce1
...
@@ -26,8 +26,6 @@ def load_function(path):
...
@@ -26,8 +26,6 @@ def load_function(path):
def
modulestore
(
name
=
'default'
):
def
modulestore
(
name
=
'default'
):
global
_MODULESTORES
if
name
not
in
_MODULESTORES
:
if
name
not
in
_MODULESTORES
:
class_
=
load_function
(
settings
.
MODULESTORE
[
name
][
'ENGINE'
])
class_
=
load_function
(
settings
.
MODULESTORE
[
name
][
'ENGINE'
])
...
...
lms/djangoapps/django_comment_client/utils.py
View file @
57909ce1
...
@@ -73,21 +73,17 @@ def get_discussion_id_map(course):
...
@@ -73,21 +73,17 @@ def get_discussion_id_map(course):
"""
"""
return a dict of the form {category: modules}
return a dict of the form {category: modules}
"""
"""
global
_DISCUSSIONINFO
initialize_discussion_info
(
course
)
initialize_discussion_info
(
course
)
return
_DISCUSSIONINFO
[
course
.
id
][
'id_map'
]
return
_DISCUSSIONINFO
[
course
.
id
][
'id_map'
]
def
get_discussion_title
(
course
,
discussion_id
):
def
get_discussion_title
(
course
,
discussion_id
):
global
_DISCUSSIONINFO
initialize_discussion_info
(
course
)
initialize_discussion_info
(
course
)
title
=
_DISCUSSIONINFO
[
course
.
id
][
'id_map'
]
.
get
(
discussion_id
,
{})
.
get
(
'title'
,
'(no title)'
)
title
=
_DISCUSSIONINFO
[
course
.
id
][
'id_map'
]
.
get
(
discussion_id
,
{})
.
get
(
'title'
,
'(no title)'
)
return
title
return
title
def
get_discussion_category_map
(
course
):
def
get_discussion_category_map
(
course
):
global
_DISCUSSIONINFO
initialize_discussion_info
(
course
)
initialize_discussion_info
(
course
)
return
filter_unstarted_categories
(
_DISCUSSIONINFO
[
course
.
id
][
'category_map'
])
return
filter_unstarted_categories
(
_DISCUSSIONINFO
[
course
.
id
][
'category_map'
])
...
@@ -141,8 +137,6 @@ def sort_map_entries(category_map):
...
@@ -141,8 +137,6 @@ def sort_map_entries(category_map):
def
initialize_discussion_info
(
course
):
def
initialize_discussion_info
(
course
):
global
_DISCUSSIONINFO
course_id
=
course
.
id
course_id
=
course
.
id
discussion_id_map
=
{}
discussion_id_map
=
{}
...
...
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