Skip to content

Releases: snowflakedb/snowflake-cli

v2.4.0-rc0

28 May 09:48
Compare
Choose a tag to compare
v2.4.0-rc0 Pre-release
Pre-release

Backward incompatibility

Deprecations

New additions

  • Added the --cascade option to snow app teardown command that drops all application objects owned by the application.
  • Add external access integration to snow object commands
  • Add aliases for snow object list/describe/drop commands under:
    • snow stage for stages
    • snow git for git repository stages
    • snow streamlit for streamlit apps
    • snow snowpark for procedures and functions
    • snow spcs compute-pool for compute pools
    • snow spcs image-repository for image repositories
    • snow spcs service for services
  • snow sql works now with snowflake.yml file. The variables defined in the new env section
    of snowflake.yml will be used to expand templates.
  • snow sql support executing multiple files. Users can use -f/--file flag more than once to execute queries
    from many files.
  • snow git execute and snow stage execute support passing input variables for SQL execution.
  • Added snow cortex commands:
    • complete - Given a prompt, the command generates a response using your choice of language model.
      In the simplest use case, the prompt is a single string. You may also provide a JSON file with conversation history including multiple prompts and responses for interactive chat-style usage.
    • extract-answer - Extracts an answer to a given question from a text document.
      The document may be a plain-English document or a string representation of a semi-structured (JSON) data object.
    • sentiment - Returns sentiment as a score between -1 to 1 (with -1 being the most negative and 1 the most positive, with values around 0 neutral) for the given English-language input text.
    • summarize - Summarizes the given English-language input text.
    • translate - Translates text from the indicated or detected source language to a target language.
    • search - for integration with Cortex Search Service
  • When invoked without command help is displayed by default with list of available commands.
  • Add tab-completion for snow command.

Fixes and improvements

  • Improved support for quoted identifiers.
  • Fixed creating patches with snow app version create when there are 2 or more existing patches on a version
  • Using --format=json adds trailing new line to avoid % being added by some terminals to signal no new line at the end of output.
  • Fixed --interactive flag to be enabled by default in interactive environments and added the --no-interactive flag to be able to turn off prompting.

v2.3.1

20 May 11:11
Compare
Choose a tag to compare

Backward incompatibility

Deprecations

New additions

Fixes and improvements

  • Fixed bugs in source artifact mapping logic for native applications

v2.3.0

15 May 13:17
36d1a98
Compare
Choose a tag to compare

Backward incompatibility

Deprecations

New additions

  • New snow sql functionality:
    • -D/--variable allows variable substitutions in a SQL input (client-side query templating)
  • New snow app deploy functionality:
    • Passing files and directories as arguments syncs these only: snow app deploy some-file some-dir.
    • --recursive syncs all files and subdirectories recursively.
    • --prune deletes specified files from the stage if they don't exist locally.

Fixes and improvements

  • More human-friendly errors in case of corrupted config.toml file.
  • Fixed a bug in snow app that caused files to be re-uploaded unnecessarily.
  • Optimize snowpark dependency search to lower the size of .zip artifacts and
    the number of anaconda dependencies for snowpark projects.
  • Added support for fully qualified stage names in stage and git execute commands.
  • Fixed a bug where snow app run was not upgrading the application when the local state and remote stage are identical (for example immediately after snow app deploy).
  • Fixed handling of stage path separators on Windows
  • The --info callback returns info about configured feature flags.

v2.3.0-rc1

14 May 14:55
Compare
Choose a tag to compare
v2.3.0-rc1 Pre-release
Pre-release

Backward incompatibility

Deprecations

New additions

  • New snow sql functionality:
    • -D/--variable allows variable substitutions in a SQL input (client-side query templating)
  • New snow app deploy functionality:
    • Passing files and directories as arguments syncs these only: snow app deploy some-file some-dir.
    • --recursive syncs all files and subdirectories recursively.
    • --prune deletes specified files from the stage if they don't exist locally.

Fixes and improvements

  • More human-friendly errors in case of corrupted config.toml file.
  • Fixed a bug in snow app that caused files to be re-uploaded unnecessarily.
  • Optimize snowpark dependency search to lower the size of .zip artifacts and
    the number of anaconda dependencies for snowpark projects.
  • Added support for fully qualified stage names in stage and git execute commands.
  • Fixed a bug where snow app run was not upgrading the application when the local state and remote stage are identical (for example immediately after snow app deploy).
  • Fixed handling of stage path separators on Windows
  • The --info callback returns info about configured feature flags.

v2.3.0-rc0

09 May 15:15
908cf13
Compare
Choose a tag to compare
v2.3.0-rc0 Pre-release
Pre-release

Backward incompatibility

Deprecations

New additions

  • New snow sql functionality:
    • -D/--data allows variable substitutions in a SQL input (client-side query templating)
  • New snow app deploy functionality:
    • Passing files and directories as arguments syncs these only: snow app deploy some-file some-dir.
    • --recursive syncs all files and subdirectories recursively.
    • --prune deletes specified files from the stage if they don't exist locally.

Fixes and improvements

  • More human-friendly errors in case of corrupted config.toml file.
  • Fixed a bug in snow app that caused files to be re-uploaded unnecessarily.
  • Optimize snowpark dependency search to lower the size of .zip artifacts and
    the number of anaconda dependencies for snowpark projects.
  • Added support for fully qualified stage names in stage and git execute commands.
  • Fixed a bug where snow app run was not upgrading the application when the local state and remote stage are identical (for example immediately after snow app deploy).
  • Fixed handling of stage path separators on Windows
  • The --info callback returns info about configured feature flags.

v2.2.0

25 Apr 12:17
Compare
Choose a tag to compare

Deprecations

  • snow snowpark package lookup no longer performs check against PyPi. Using --pypi-download or --yes
    has no effect and will cause a warning. In this way the command has single responsibility - check if package is
    available in Snowflake Anaconda channel.
  • snow snowpark package create:
    • --pypi-download or --yes flags are deprecated, have no effect and will cause a warning.
      create command always checks against PyPi.
    • --allow-native-libraries is deprecated in favour of boolean flag --allow-shared-libraries.
      Using old flag will cause a warning.
  • snow snowpark build:
    • --pypi-download flag is deprecated, have no effect and will cause a warning. Build command always check against PyPi.
    • --check-anaconda-for-pypi-depts is deprecated and using it will cause warning, the functionality is replaced by --ignore-anaconda
    • --package-native-libraries is deprecated and using it will cause warning, the functionality is replaced by --allow-shared-libraries
  • snow object stage commands are deprecated and using them will cause a warning.
    Functionality is replaced by snow stage commands.

New additions

  • Added support for fully qualified name (database.schema.name) in name parameter in streamlit project definition
  • Added support for fully qualified image repository names in spcs image-repository commands.
  • Added --if-not-exists option to create commands for service, and compute-pool. Added --replace and --if-not-exists options for image-repository create.
  • Added support for python connector diagnostic report.
  • Added snow app deploy command that creates an application package and syncs the local changes to the stage without creating or updating the application.
  • Added is_default column to snow connection list output to highlight default connection.
  • snow snowpark package create:
    • new --ignore-anaconda flag disables package lookup in Snowflake Anaconda channel.
      All dependencies will be downloaded from PyPi.
    • new --skip-version-check skips comparing versions of dependencies between requirements and Anaconda.
    • new --index-url flag sets up Base URL of the Python Package Index to use for package lookup.
  • snow snowpark build:
    • new --skip-version-check skips comparing versions of dependencies between requirements and Anaconda.
    • new --index-url flag sets up Base URL of the Python Package Index to use for package lookup.
  • Added --recursive flag for copy from stage, it will reproduce the directory structure locally.
  • Added support for snowgit. New commands:
    • snow git setup - wizard setting up a git repository stage and creating all necessary objects
    • snow git fetch - fetches latest changes from the origin repository into Snowflake repository
    • snow git list-branches - lists all branches in the repository
    • snow git list-tags - lists all tags in the repository
    • snow git list-files - lists all files on provided branch/tag/commit
    • snow git copy - copies files from provided branch/tag/commit into stage or local directory
    • snow git execute - execute immediate files from repository
  • Added command for execute immediate snow stage execute
  • Fetching available packages list from Snowflake instead of directly from Anaconda with fallback to the old method (for backward compatibility).
    As the new method requires a connection to Snowflake, it adds connection options to the following commands:
    • snow snowpark build
    • snow snowpark package lookup
    • snow snowpark package create

Fixes and improvements

  • Adding --image-name option for image name argument in spcs image-repository list-tags for consistency with other commands.
  • Fixed errors during spcs image-registry login not being formatted correctly.
  • Project definition no longer accept extra fields. Any extra field will cause an error.
  • Changing imports in function/procedure section in snowflake.yml will cause the definition update on replace
  • Adding --pattern flag to stage list-files command for filtering out results with regex.
  • Fixed snowpark build paths for builds with --project option (fixed empty zip issue).
  • More clear error messages in snow snowpark build command
  • Adding support for any source supported by pip in snow snowpark.
  • Fixed version parsing for packages lookup on Snowflake Anaconda Channel
  • Fix handling database/schema/role identifiers containing dashes
  • Fix schema override bug in snow connection test
  • Hidden incorrectly working config permissions warning on Windows
  • Make errors from snow connection test more meaningful when role, warehouse or database does not exist.

v2.2.0-rc0

18 Apr 13:32
cd40584
Compare
Choose a tag to compare
v2.2.0-rc0 Pre-release
Pre-release

Deprecations

  • snow snowpark package lookup no longer performs check against PyPi. Using --pypi-download or --yes
    has no effect and will cause a warning. In this way the command has single responsibility - check if package is
    available in Snowflake Anaconda channel.
  • snow snowpark package create:
    • --pypi-download or --yes flags are deprecated, have no effect and will cause a warning.
      create command always checks against PyPi.
    • --allow-native-libraries is deprecated in favour of boolean flag --allow-shared-libraries.
      Using old flag will cause a warning.
  • snow snowpark build:
    • --pypi-download flag is deprecated, have no effect and will cause a warning. Create command always check against PyPi.
    • --check-anaconda-for-pypi-depts is deprecated and using it will cause warning, the functionality is replaced by --ignore-anaconda
    • --package-native-libraries is deprecated and using it will cause warning, the functionality is replaced by --allow-shared-libraries
  • snow object stage commands are deprecated and using them will cause a warning.
    Functionality is replaced by snow stage commands.

New additions

  • Added support for fully qualified name (database.schema.name) in name parameter in streamlit project definition
  • Added support for fully qualified image repository names in spcs image-repository commands.
  • Added --if-not-exists option to create commands for service, and compute-pool. Added --replace and --if-not-exists options for image-repository create.
  • Added support for python connector diagnostic report.
  • Added snow app deploy command that creates an application package and syncs the local changes to the stage without creating or updating the application.
  • Added is_default column to snow connection list output to highlight default connection.
  • snow snowpark package create:
    • new --ignore-anaconda flag disables package lookup in Snowflake Anaconda channel.
      All dependencies will be downloaded from PyPi.
    • new --skip-version-check skips comparing versions of dependencies between requirements and Anaconda.
    • new --index-url flag sets up Base URL of the Python Package Index to use for package lookup.
  • snow snowpark build:
    • new --skip-version-check skips comparing versions of dependencies between requirements and Anaconda.
    • new --index-url flag sets up Base URL of the Python Package Index to use for package lookup.
  • Added --recursive flag for copy from stage, it will reproduce the directory structure locally.
  • Added support for snowgit. New commands:
    • snow git setup - wizard setting up a git repository stage and creating all necessary objects
    • snow git fetch - fetches latest changes from the origin repository into Snowflake repository
    • snow git list-brahces - lists all branches in the repository
    • snow git list-tags - lists all tags in the repository
    • snow git list-files - lists all files on provided branch/tag/commit
    • snow git copy - copies files from provided branch/tag/commit into stage or local directory
    • snow git execute - execute immediate files from repository
  • Added command for execute immediate snow object stage execute
  • Fetching available packages list from Snowflake instead of directly from Anaconda with fallback to the old method (for backward compatibility).
    As the new method requires a connection to Snowflake, it adds connection options to the following commands:
    • snow snowpark build
    • snow snowpark package lookup
    • snow snowpark package create

Fixes and improvements

  • Adding --image-name option for image name argument in spcs image-repository list-tags for consistency with other commands.
  • Fixed errors during spcs image-registry login not being formatted correctly.
  • Project definition no longer accept extra fields. Any extra field will cause an error.
  • Changing imports in function/procedure section in snowflake.yml will cause the definition update on replace
  • Adding --pattern flag to stage list command for filtering out results with regex.
  • Fixed snowpark build paths for builds with --project option (fixed empty zip issue).
  • More clear error messages in snow snowpark build command
  • Adding support for any source supported by pip in snow snowpark.
  • Fixed version parsing for packages lookup on Snowflake Anaconda Channel
  • Fix handling database/schema/role identifiers containing dashes
  • Fix schema override bug in snow connection test
  • Hidden incorrectly working config permissions warning on Windows

v2.1.2

27 Mar 11:52
Compare
Choose a tag to compare

Fixes and improvements

  • Add pip as Snowflake-cli dependency
  • Optimize connection test command
  • Fix venv creation issues in snowpark package create and snowpark build command

v2.1.1

19 Mar 15:04
Compare
Choose a tag to compare

Fixes and improvements

  • Improved security of printing connection details in snow connection list.
  • Improved parsing of non-quoted scalar values within square brackets in manifest.yml in Native App projects.

v2.1.0

07 Mar 13:56
Compare
Choose a tag to compare

New additions

  • Added ability to specify scope of the object list command with the --in <scope_type> <scope_name> option.

  • Introduced snowflake.cli.api.console.cli_console object with helper methods for intermediate output.

  • Added new --mfa-passcode flag to support MFA.

  • Added possibility to specify database and schema in snowflake.yml for snowpark objects. Also name can specify a fully qualify name.

  • New commands for spcs

    • Added image-registry url command to get the URL for your account image registry.
    • Added image-registry login command to fetch authentication token and log in to image registry in one command.
    • Added image-repository url <repo_name> command to get the URL for specified image repository.
    • Added create command for image-repository.
    • Added status, set (property), unset (property), suspend and resume commands for compute-pool.
    • Added set (property), unset (property),upgrade and list-endpoints commands for service.
  • Connections parameters are also supported by generic environment variables:

    • SNOWFLAKE_ACCOUNT
    • SNOWFLAKE_USER
    • SNOWFLAKE_PASSWORD
    • SNOWFLAKE_DATABASE
    • SNOWFLAKE_SCHEMA
    • SNOWFLAKE_ROLE
    • SNOWFLAKE_WAREHOUSE
    • SNOWFLAKE_MFA_PASSCODE
  • Introduced --pypi-download flag for snow snowpark package commands to replace -y and --yes

    The SNOWFLAKE_CONNECTION_<NAME>_<KEY> variable takes precedence before the generic flag. For example if
    SNOWFLAKE_PASSWORD and SNOWFLAKE_CONNECTIONS_FOO_PASSWORD are present and user tries to use connection
    "foo" then the later variable will be used.

  • Testing connection using snow connection test validates also access to database, schema, role and warehouse
    specified in the connection details.

  • Added snow connection set-default command for changing default connection.

Fixes and improvements

  • Restricted permissions of automatically created files
  • Fixed bug where spcs service create would not throw error if service with specified name already exists.
  • Logging into the file by default (INFO level)
  • Added validation that service, compute pool, and image repository names are unqualified identifiers.
  • spcs service commands now accept qualified names.
  • Updated help messages for spcs commands.