snowflakedb/snowflake-cli

SNOW-1020543: snowflake.local.yml overrides cause error for list fields

Closed this issue · 1 comments

SnowCLI version

SnowCLI Version: 2.0.0a3

Python version

Python 3.8.12

Platform

macOS-14.2.1-arm64-arm-64bit

What happened

snowflake.yml

definition_version: 1
streamlit:
  name: streamlit_core_metrics_prod
  query_warehouse: streamlit_medium
  main_file: streamlit_app.py
  env_file: environment.yml
  database: streamlit
  schema: sis_apps
  role: streamlit_product_rl
  pages_dir: pages/
  additional_source_files:
    - shared_modules/*.py
    - shared_modules/adoption/*.py
    - shared_modules/companies/*.py
    - shared_modules/metrics/*.py
    - shared_modules/page_profiling/*.py
    - shared_modules/scrape_huggingface/*.py
    - pages.toml
    - data/*.csv

snowflake.local.yml

definition_version: 1
streamlit:
  name: streamlit_core_metrics_preview
  additional_source_files:
    - shared_modules/*.py

Console output

TypeError: YAML(['shared_modules/*.py']) not a mapping, cannot use .items()

How to reproduce

Try to override a field from snowflake.yml that contains a list in snowflake.local.yml -- it only seems to work with 1-to-1 mapping fields, rather than 1-to-list fields.