Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
edx-platform-release
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
1
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Hsin-Yu Chien
edx-platform-release
Commits
efd0c60c
Unverified
Commit
efd0c60c
authored
5 years ago
by
Feanil Patel
Committed by
GitHub
5 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #22560 from edx/feanil/ensure_tarfile_not_binary
Make the file name not have a 'b' prefix.
parents
7d48feac
50ab035d
No related branches found
Branches containing commit
Tags
release-2019-12-19-10.16
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
cms/djangoapps/contentstore/tasks.py
+4
-1
4 additions, 1 deletion
cms/djangoapps/contentstore/tasks.py
with
4 additions
and
1 deletion
cms/djangoapps/contentstore/tasks.py
+
4
−
1
View file @
efd0c60c
...
@@ -32,7 +32,7 @@ from opaque_keys.edx.locator import LibraryLocator, BlockUsageLocator
...
@@ -32,7 +32,7 @@ from opaque_keys.edx.locator import LibraryLocator, BlockUsageLocator
from
organizations.models
import
OrganizationCourse
from
organizations.models
import
OrganizationCourse
from
path
import
Path
as
path
from
path
import
Path
as
path
from
pytz
import
UTC
from
pytz
import
UTC
from
six
import
iteritems
,
text_type
from
six
import
iteritems
,
text_type
,
binary_type
from
six.moves
import
range
from
six.moves
import
range
from
user_tasks.models
import
UserTaskArtifact
,
UserTaskStatus
from
user_tasks.models
import
UserTaskArtifact
,
UserTaskStatus
from
user_tasks.tasks
import
UserTask
from
user_tasks.tasks
import
UserTask
...
@@ -630,6 +630,9 @@ def create_export_tarball(course_module, course_key, context, status=None):
...
@@ -630,6 +630,9 @@ def create_export_tarball(course_module, course_key, context, status=None):
Updates the context with any error information if applicable.
Updates the context with any error information if applicable.
"""
"""
name
=
course_module
.
url_name
name
=
course_module
.
url_name
if
isinstance
(
name
,
binary_type
):
name
=
name
.
decode
(
'
utf-8
'
)
export_file
=
NamedTemporaryFile
(
prefix
=
name
+
'
.
'
,
suffix
=
"
.tar.gz
"
)
export_file
=
NamedTemporaryFile
(
prefix
=
name
+
'
.
'
,
suffix
=
"
.tar.gz
"
)
root_dir
=
path
(
mkdtemp
())
root_dir
=
path
(
mkdtemp
())
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment