Skip to content

Conversation

@fmterrorf
Copy link

Adds an ability to read private key from an environment variable SNOWFLAKE_PRIVATE_KEY

@sfc-gh-twhite
Copy link
Collaborator

Thanks for the PR @fmterrorf! Ideally, we would like to leverage the environment variables for these credentials if possible.

Does providing those with either SNOWFLAKE_PRIVATE_KEY_PATH or SNOWFLAKE_PRIVATE_KEY_RAW work for you? These credential environment variables are documented at https://docs.snowflake.com/en/developer-guide/snowflake-cli/connecting/configure-connections#use-environment-variables-for-snowflake-credentials.

@fmterrorf
Copy link
Author

fmterrorf commented Aug 8, 2025

@sfc-gh-twhite I've tried SNOWFLAKE_PRIVATE_KEY_RAW but it does not seem to work. I'm avoiding SNOWFLAKE_PRIVATE_KEY_PATH since I don't want to write the private key file. The CLI has this line of code https://github.com/snowflakedb/snowflake-cli/blob/e62ddfcdbccbaa7d1b7a39d700c8d2e6945b9a8a/src/snowflake/cli/_app/snow_connector.py#L228-L230 that reads SNOWFLAKE_PRIVATE_KEY_RAW from the env variable. Schemachange don't have that currently

@sfc-gh-twhite
Copy link
Collaborator

@sfc-gh-twhite I've tried SNOWFLAKE_PRIVATE_KEY_RAW but it does not seem to work. I'm avoiding SNOWFLAKE_PRIVATE_KEY_PATH since I don't want to write the private key file. The CLI has this line of code https://github.com/snowflakedb/snowflake-cli/blob/e62ddfcdbccbaa7d1b7a39d700c8d2e6945b9a8a/src/snowflake/cli/_app/snow_connector.py#L228-L230 that reads SNOWFLAKE_PRIVATE_KEY_RAW from the env variable. Schemachange don't have that currently

Understood! Thank you for this info.

We have many open issues related to this topic, so I plan to address them this week. Noting here to check if the following will be resolved, as they seem similar:

@sfc-gh-tmathew sfc-gh-tmathew added the enhancement New feature or request label Aug 29, 2025
@andrew-davey
Copy link

@sfc-gh-twhite is there an ETA on when this enhancement will be released?

@sfc-gh-tmathew
Copy link
Collaborator

@andrew-davey 4.1.0 is going to be released soon. As for the specific private key issue, we will prioritize this immediately after 4.1.0 release this week and include it in the 4.2.0 release before the holidays in December.

Thank you for your contribution. Once 4.1.0 is released, if you could update your contribution to be based on as an bug fix to 4.1.0 would be appreciated.

@sfc-gh-tmathew
Copy link
Collaborator

@fmterrorf 4.1.0 has addressed backward compatibility with mismatched variable names in favor of aligning with python connector's parameter names. Could you retest this PR against 4.1.0 and confirm if you still need to merge this PR or can close this out.

We sincerely appreciate your patience and your contribution to the project. We are trying to streamline a predictable release cadence and staying on top of requests and will need time to catch up.

Kindly respond back with your tests and resolving the merge conflict if you want the PR to be merged to master.

@sfc-gh-tmathew sfc-gh-tmathew added Under Review This is being discussed without planned changes community-contribution Submitted by community target: 4.2.0 Planned for 4.2.0 release and removed Under Review This is being discussed without planned changes labels Nov 18, 2025
@sfc-gh-tmathew sfc-gh-tmathew changed the base branch from master to rc4.2.0 November 18, 2025 21:24
Copy link
Collaborator

@sfc-gh-tmathew sfc-gh-tmathew left a comment

Choose a reason for hiding this comment

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

Could you attempt to resolve the merge conflicts and let us know soon enough to include the PR in 4.2.0 OR we can slate it for a later release.

@sfc-gh-tmathew sfc-gh-tmathew changed the base branch from rc4.2.0 to master November 18, 2025 21:33
@fmterrorf
Copy link
Author

@sfc-gh-tmathew sorry i currently don't have time to do so. I'll probably get to it this weekend

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community-contribution Submitted by community enhancement New feature or request target: 4.2.0 Planned for 4.2.0 release

Projects

None yet

4 participants