Skip to content

Move unsafe_file_write parameter to DEFAULT_CONFIGURATION#2413

Merged
sfc-gh-pczajka merged 2 commits intomainfrom
SNOW-2207863-add-unsafe-file-write-to-default-parameters
Jul 22, 2025
Merged

Move unsafe_file_write parameter to DEFAULT_CONFIGURATION#2413
sfc-gh-pczajka merged 2 commits intomainfrom
SNOW-2207863-add-unsafe-file-write-to-default-parameters

Conversation

@sfc-gh-pczajka
Copy link
Collaborator

  1. What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.

    Fixes SNOW-2207863

  2. Fill out the following pre-review checklist:

    • I am adding a new automated test(s) to verify correctness of my new code
    • I am adding new logging messages
    • I am adding a new telemetry message
    • I am modifying authorization mechanisms
    • I am adding new credentials
    • I am modifying OCSP code
    • I am adding a new dependency
  3. Please describe how your code solves the related issue.

    Move unsafe_file_write parameter to default configuration. Otherwise accessing this connection property before calling connect() might've result in an error

@sfc-gh-pczajka sfc-gh-pczajka added NO-CHANGELOG-UPDATES This pull request does not need to update CHANGELOG.md DO_NOT_PORT_CHANGES_TO_SP labels Jul 17, 2025
if "host" not in kwargs:
self._host = construct_hostname(kwargs.get("region"), self._account)

if "unsafe_file_write" in kwargs:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add a quick test that by default our driver behaves in the way that unsafe_file_write = False describes.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, then we are good 👍

I found the second test before, but I think we set there explicitly the value to True so it wasn't preventing changes in the default behaviour in the future.

Nevertheless, the first test You attached is what I needed indeed.

@sfc-gh-pczajka sfc-gh-pczajka merged commit 94afe8a into main Jul 22, 2025
95 of 99 checks passed
@sfc-gh-pczajka sfc-gh-pczajka deleted the SNOW-2207863-add-unsafe-file-write-to-default-parameters branch July 22, 2025 10:47
@github-actions github-actions bot locked and limited conversation to collaborators Jul 22, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

NO-CHANGELOG-UPDATES This pull request does not need to update CHANGELOG.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants