Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
pyfs
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
OpenEdx
pyfs
Commits
9bd05e3b
Commit
9bd05e3b
authored
Jun 17, 2009
by
rfkelly0
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Wrap use of shutil.copyfile() in convet_os_errors() decorator, for cleaner error reporting
parent
38e0f457
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletions
+4
-1
fs/base.py
+4
-1
No files found.
fs/base.py
View file @
9bd05e3b
...
@@ -497,7 +497,7 @@ class FS(object):
...
@@ -497,7 +497,7 @@ class FS(object):
dst_syspath
=
self
.
getsyspath
(
dst
,
allow_none
=
True
)
dst_syspath
=
self
.
getsyspath
(
dst
,
allow_none
=
True
)
if
src_syspath
is
not
None
and
dst_syspath
is
not
None
:
if
src_syspath
is
not
None
and
dst_syspath
is
not
None
:
s
hutil
.
copyfile
(
src_syspath
,
dst_syspath
)
s
elf
.
_shutil_
copyfile
(
src_syspath
,
dst_syspath
)
else
:
else
:
src_file
,
dst_file
=
None
,
None
src_file
,
dst_file
=
None
,
None
try
:
try
:
...
@@ -515,6 +515,9 @@ class FS(object):
...
@@ -515,6 +515,9 @@ class FS(object):
if
dst_file
is
not
None
:
if
dst_file
is
not
None
:
dst_file
.
close
()
dst_file
.
close
()
@convert_os_errors
def
_shutil_copyfile
(
self
,
src_syspath
,
dst_syspath
):
shutil
.
copyfile
(
src_syspath
,
dst_syspath
)
def
move
(
self
,
src
,
dst
,
overwrite
=
False
,
chunk_size
=
16384
):
def
move
(
self
,
src
,
dst
,
overwrite
=
False
,
chunk_size
=
16384
):
"""Moves a file from one location to another.
"""Moves a file from one location to another.
...
...
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