Skip to content
This repository was archived by the owner on Jul 7, 2023. It is now read-only.

Commit 0878242

Browse files
authored
Merge pull request #584 from bbarnes52/master
update invalid tf.gfile.Move to tf.gfile.Copy followed by tf.gfile.Remove
2 parents 37ced7c + e8456d4 commit 0878242

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tensor2tensor/utils/cloud_mlengine.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,8 @@ def tar_and_copy_usr_dir(usr_dir, train_dir):
179179
top_setup_fname = os.path.join(top_dir, 'setup.py')
180180
usr_setup_fname = os.path.join(tmp_usr_dir, 'setup.py')
181181
if tf.gfile.Exists(usr_setup_fname):
182-
tf.gfile.Move(usr_setup_fname, top_setup_fname)
182+
tf.gfile.Copy(usr_setup_fname, top_setup_fname)
183+
tf.gfile.Remove(usr_setup_fname)
183184
else:
184185
with tf.gfile.Open(top_setup_fname, 'w') as f:
185186
f.write(SETUP_PY)

0 commit comments

Comments
 (0)