We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8cba605 commit 7c0d4b2Copy full SHA for 7c0d4b2
1 file changed
coderdata/download/downloader.py
@@ -4,6 +4,7 @@
4
from os import PathLike
5
import os
6
import requests
7
+import warnings
8
9
def download(
10
name: str=None,
@@ -86,7 +87,7 @@ def download(
86
87
with requests.get(file_url, stream=True) as r:
88
r.raise_for_status()
89
if file_name.exists() and not exist_ok:
- os.warn(
90
+ warnings.warn(
91
f"{file_name} already exists. Use argument 'exist_ok=True'"
92
"to overwrite existing file."
93
)
0 commit comments