Skip to content

Commit 7e791ac

Browse files
Move unsafe_file_write parameter to DEFAULT_CONFIGURATION (#2413)
1 parent 8c8cd1e commit 7e791ac

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/snowflake/connector/connection.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -305,6 +305,10 @@ def _get_private_bytes_from_file(
305305
None,
306306
(type(None), int),
307307
), # SNOW-1817982: limit iobound TPE sizes when executing PUT/GET
308+
"unsafe_file_write": (
309+
False,
310+
bool,
311+
), # SNOW-1944208: add unsafe write flag
308312
}
309313

310314
APPLICATION_RE = re.compile(r"[\w\d_]+")
@@ -1243,11 +1247,6 @@ def __config(self, **kwargs):
12431247
if "protocol" not in kwargs:
12441248
self._protocol = "https"
12451249

1246-
if "unsafe_file_write" in kwargs:
1247-
self._unsafe_file_write = kwargs["unsafe_file_write"]
1248-
else:
1249-
self._unsafe_file_write = False
1250-
12511250
logger.info(
12521251
f"Connecting to {_DOMAIN_NAME_MAP.get(extract_top_level_domain_from_hostname(self._host), 'GLOBAL')} Snowflake domain"
12531252
)

0 commit comments

Comments
 (0)