Skip to content

Commit 10b8afb

Browse files
committed
Override failure to find file if it has been deleted already.
1 parent d497cba commit 10b8afb

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

notes/L2-Folders.ipynb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,10 @@
437437
"outputs": [],
438438
"source": [
439439
"for fname in [ 'temporary.txt','temp2.txt', 'temp3.txt']:\n",
440-
" os.remove(fname) # Remove each of our files in \"practice_files\" "
440+
" try:\n",
441+
" os.remove(fname) # Remove each of our files in \"practice_files\" \n",
442+
" except:\n",
443+
" print(f\"Couldn't find {fname}\")"
441444
]
442445
},
443446
{

0 commit comments

Comments
 (0)