snowflake-cli-labs 3.0.0rc1__py3-none-any.whl → 3.0.0rc2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. snowflake/cli/__about__.py +1 -1
  2. snowflake/cli/_app/cli_app.py +10 -1
  3. snowflake/cli/_app/snow_connector.py +76 -29
  4. snowflake/cli/_app/telemetry.py +8 -4
  5. snowflake/cli/_app/version_check.py +74 -0
  6. snowflake/cli/_plugins/git/commands.py +55 -14
  7. snowflake/cli/_plugins/nativeapp/codegen/snowpark/python_processor.py +2 -5
  8. snowflake/cli/_plugins/nativeapp/codegen/templates/templates_processor.py +49 -31
  9. snowflake/cli/_plugins/nativeapp/manager.py +46 -87
  10. snowflake/cli/_plugins/nativeapp/run_processor.py +56 -260
  11. snowflake/cli/_plugins/nativeapp/same_account_install_method.py +74 -0
  12. snowflake/cli/_plugins/nativeapp/teardown_processor.py +9 -152
  13. snowflake/cli/_plugins/nativeapp/v2_conversions/v2_to_v1_decorator.py +91 -17
  14. snowflake/cli/_plugins/snowpark/commands.py +1 -1
  15. snowflake/cli/_plugins/snowpark/models.py +2 -1
  16. snowflake/cli/_plugins/streamlit/commands.py +1 -1
  17. snowflake/cli/_plugins/streamlit/manager.py +9 -0
  18. snowflake/cli/_plugins/workspace/action_context.py +2 -1
  19. snowflake/cli/_plugins/workspace/commands.py +48 -16
  20. snowflake/cli/_plugins/workspace/manager.py +1 -0
  21. snowflake/cli/api/cli_global_context.py +136 -313
  22. snowflake/cli/api/commands/flags.py +76 -91
  23. snowflake/cli/api/commands/snow_typer.py +6 -4
  24. snowflake/cli/api/config.py +1 -1
  25. snowflake/cli/api/connections.py +214 -0
  26. snowflake/cli/api/console/abc.py +4 -2
  27. snowflake/cli/api/entities/application_entity.py +687 -2
  28. snowflake/cli/api/entities/application_package_entity.py +151 -46
  29. snowflake/cli/api/entities/common.py +1 -0
  30. snowflake/cli/api/entities/utils.py +41 -17
  31. snowflake/cli/api/identifiers.py +3 -0
  32. snowflake/cli/api/project/definition.py +11 -0
  33. snowflake/cli/api/project/definition_conversion.py +171 -13
  34. snowflake/cli/api/project/schemas/entities/common.py +0 -12
  35. snowflake/cli/api/project/schemas/identifier_model.py +2 -2
  36. snowflake/cli/api/project/schemas/project_definition.py +101 -39
  37. snowflake/cli/api/rendering/project_definition_templates.py +4 -0
  38. snowflake/cli/api/rendering/sql_templates.py +7 -0
  39. snowflake/cli/api/utils/definition_rendering.py +3 -1
  40. {snowflake_cli_labs-3.0.0rc1.dist-info → snowflake_cli_labs-3.0.0rc2.dist-info}/METADATA +6 -6
  41. {snowflake_cli_labs-3.0.0rc1.dist-info → snowflake_cli_labs-3.0.0rc2.dist-info}/RECORD +44 -42
  42. snowflake/cli/api/commands/typer_pre_execute.py +0 -26
  43. {snowflake_cli_labs-3.0.0rc1.dist-info → snowflake_cli_labs-3.0.0rc2.dist-info}/WHEEL +0 -0
  44. {snowflake_cli_labs-3.0.0rc1.dist-info → snowflake_cli_labs-3.0.0rc2.dist-info}/entry_points.txt +0 -0
  45. {snowflake_cli_labs-3.0.0rc1.dist-info → snowflake_cli_labs-3.0.0rc2.dist-info}/licenses/LICENSE +0 -0
@@ -24,7 +24,6 @@ from snowflake.cli.api.project.schemas.entities.application_entity_model import
24
24
  ApplicationEntityModel,
25
25
  )
26
26
  from snowflake.cli.api.project.schemas.entities.common import (
27
- DefaultsField,
28
27
  TargetField,
29
28
  )
30
29
  from snowflake.cli.api.project.schemas.entities.entities import (
@@ -42,6 +41,7 @@ from snowflake.cli.api.utils.types import Context
42
41
  from typing_extensions import Annotated
43
42
 
44
43
  AnnotatedEntity = Annotated[EntityModel, Field(discriminator="type")]
44
+ scalar = str | int | float | bool
45
45
 
46
46
 
47
47
  @dataclass
@@ -62,6 +62,11 @@ class ProjectProperties:
62
62
  project_context: Context
63
63
 
64
64
 
65
+ @dataclass
66
+ class YamlOverride:
67
+ data: dict | list
68
+
69
+
65
70
  class _ProjectDefinitionBase(UpdatableModel):
66
71
  def __init__(self, *args, **kwargs):
67
72
  try:
@@ -114,31 +119,12 @@ class DefinitionV11(DefinitionV10):
114
119
  class DefinitionV20(_ProjectDefinitionBase):
115
120
  entities: Dict[str, AnnotatedEntity] = Field(title="Entity definitions.")
116
121
 
117
- @model_validator(mode="before")
118
- @classmethod
119
- def apply_defaults(cls, data: Dict) -> Dict:
120
- """
121
- Applies default values that exist on the model but not specified in yml
122
- """
123
- if "defaults" in data and "entities" in data:
124
- for key, entity in data["entities"].items():
125
- entity_fields = get_allowed_fields_for_entity(entity)
126
- if not entity_fields:
127
- continue
128
- for default_key, default_value in data["defaults"].items():
129
- if default_key in entity_fields and default_key not in entity:
130
- entity[default_key] = default_value
131
- return data
132
-
133
- @field_validator("entities", mode="after")
134
- @classmethod
135
- def validate_entities_identifiers(
136
- cls, entities: Dict[str, EntityModel]
137
- ) -> Dict[str, EntityModel]:
138
- for key, entity in entities.items():
122
+ @model_validator(mode="after")
123
+ def validate_entities_identifiers(self):
124
+ for key, entity in self.entities.items():
139
125
  entity.set_entity_id(key)
140
126
  entity.validate_identifier()
141
- return entities
127
+ return self
142
128
 
143
129
  @field_validator("entities", mode="after")
144
130
  @classmethod
@@ -179,11 +165,6 @@ class DefinitionV20(_ProjectDefinitionBase):
179
165
  f"Target type mismatch. Expected {target_type.__name__}, got {actual_target_type.__name__}"
180
166
  )
181
167
 
182
- defaults: Optional[DefaultsField] = Field(
183
- title="Default key/value entity values that are merged recursively for each entity.",
184
- default=None,
185
- )
186
-
187
168
  env: Optional[Dict[str, Union[str, int, bool]]] = Field(
188
169
  title="Default environment specification for this project.",
189
170
  default=None,
@@ -203,22 +184,92 @@ class DefinitionV20(_ProjectDefinitionBase):
203
184
  if "mixins" not in data or "entities" not in data:
204
185
  return data
205
186
 
206
- for entity in data["entities"].values():
187
+ entities = data["entities"]
188
+ for entity_name, entity in entities.items():
207
189
  entity_mixins = entity_mixins_to_list(
208
190
  entity.get("meta", {}).get("use_mixins")
209
191
  )
210
192
 
211
- entity_fields = get_allowed_fields_for_entity(entity)
212
- if entity_fields and entity_mixins:
213
- for mixin_name in entity_mixins:
214
- if mixin_name in data["mixins"]:
215
- for key, value in data["mixins"][mixin_name].items():
216
- if key in entity_fields:
217
- entity[key] = value
218
- else:
219
- raise ValueError(f"Mixin {mixin_name} not found in mixins")
193
+ merged_values = cls._merge_mixins_with_entity(
194
+ entity_id=entity_name,
195
+ entity=entity,
196
+ entity_mixins_names=entity_mixins,
197
+ mixin_defs=data["mixins"],
198
+ )
199
+ entities[entity_name] = merged_values
200
+ return data
201
+
202
+ @classmethod
203
+ def _merge_mixins_with_entity(
204
+ cls,
205
+ entity_id: str,
206
+ entity: dict,
207
+ entity_mixins_names: list,
208
+ mixin_defs: dict,
209
+ ) -> dict:
210
+ # Validate mixins
211
+ for mixin_name in entity_mixins_names:
212
+ if mixin_name not in mixin_defs:
213
+ raise ValueError(f"Mixin {mixin_name} not defined")
214
+
215
+ # Build object override data from mixins
216
+ data: dict = {}
217
+ for mx_name in entity_mixins_names:
218
+ data = cls._merge_data(data, mixin_defs[mx_name])
219
+
220
+ for key, override_value in data.items():
221
+ if key not in get_allowed_fields_for_entity(entity):
222
+ raise ValueError(
223
+ f"Unsupported key '{key}' for entity {entity_id} of type {entity['type']} "
224
+ )
225
+
226
+ entity_value = entity.get(key)
227
+ if (
228
+ entity_value is not None
229
+ and not isinstance(entity_value, YamlOverride)
230
+ and not isinstance(entity_value, type(override_value))
231
+ ):
232
+ raise ValueError(
233
+ f"Value from mixins for property {key} is of type '{type(override_value).__name__}' "
234
+ f"while entity {entity_id} expects value of type '{type(entity_value).__name__}'"
235
+ )
236
+
237
+ # Apply entity data on top of mixins
238
+ data = cls._merge_data(data, entity)
220
239
  return data
221
240
 
241
+ @classmethod
242
+ def _merge_data(
243
+ cls,
244
+ left: dict | list | scalar | None,
245
+ right: dict | list | scalar | None | YamlOverride,
246
+ ):
247
+ """
248
+ Merges right data into left. Right and left is expected to be of the same type, if not right is returned.
249
+ If left is sequence then missing elements from right are appended.
250
+ If left is dictionary then we update it with data from right. The update is done recursively key by key.
251
+ """
252
+ if isinstance(right, YamlOverride):
253
+ return right.data
254
+
255
+ if left is None:
256
+ return right
257
+
258
+ # At that point left and right are of the same type
259
+ if isinstance(left, dict) and isinstance(right, dict):
260
+ data = dict(left)
261
+ for key in right:
262
+ data[key] = cls._merge_data(left=data.get(key), right=right[key])
263
+ return data
264
+
265
+ if isinstance(left, list) and isinstance(right, list):
266
+ return _unique_extend(left, right)
267
+
268
+ if not isinstance(right, type(left)):
269
+ raise ValueError(f"Could not merge {type(right)} and {type(left)}.")
270
+
271
+ return right
272
+
222
273
  def get_entities_by_type(self, entity_type: str):
223
274
  return {i: e for i, e in self.entities.items() if e.get_type() == entity_type}
224
275
 
@@ -263,8 +314,19 @@ def get_allowed_fields_for_entity(entity: Dict[str, Any]) -> List[str]:
263
314
  Get the allowed fields for the given entity.
264
315
  """
265
316
  entity_type = entity.get("type")
317
+ if entity_type is None:
318
+ raise ValueError("Entity is missing type declaration.")
319
+
266
320
  if entity_type not in v2_entity_model_types_map:
267
321
  return []
268
322
 
269
323
  entity_model = v2_entity_model_types_map[entity_type]
270
324
  return entity_model.model_fields
325
+
326
+
327
+ def _unique_extend(list_a: List, list_b: List) -> List:
328
+ new_list = list(list_a)
329
+ for item in list_b:
330
+ if item not in list_a:
331
+ new_list.append(item)
332
+ return new_list
@@ -24,6 +24,10 @@ _YML_TEMPLATE_START = "<%"
24
24
  _YML_TEMPLATE_END = "%>"
25
25
 
26
26
 
27
+ def has_client_side_templates(template_content: str) -> bool:
28
+ return _YML_TEMPLATE_START in template_content
29
+
30
+
27
31
  def get_client_side_jinja_env() -> Environment:
28
32
  _random_block = "___very___unique___block___to___disable___logic___blocks___"
29
33
  return env_bootstrap(
@@ -55,6 +55,13 @@ def _does_template_have_env_syntax(env: Environment, template_content: str) -> b
55
55
  return bool(meta.find_undeclared_variables(template))
56
56
 
57
57
 
58
+ def has_sql_templates(template_content: str) -> bool:
59
+ return (
60
+ _OLD_SQL_TEMPLATE_START in template_content
61
+ or _SQL_TEMPLATE_START in template_content
62
+ )
63
+
64
+
58
65
  def choose_sql_jinja_env_based_on_template_syntax(
59
66
  template_content: str, reference_name: Optional[str] = None
60
67
  ) -> Environment:
@@ -277,7 +277,9 @@ def _add_defaults_to_definition(original_definition: Definition) -> Definition:
277
277
  with context({"skip_validation_on_templates": True}):
278
278
  # pass a flag to Pydantic to skip validation for templated scalars
279
279
  # populate the defaults
280
- project_definition = build_project_definition(**original_definition)
280
+ project_definition = build_project_definition(
281
+ **copy.deepcopy(original_definition)
282
+ )
281
283
 
282
284
  definition_with_defaults = project_definition.model_dump(
283
285
  exclude_none=True, warnings=False, by_alias=True
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: snowflake-cli-labs
3
- Version: 3.0.0rc1
3
+ Version: 3.0.0rc2
4
4
  Summary: Snowflake CLI
5
5
  Project-URL: Source code, https://github.com/snowflakedb/snowflake-cli
6
6
  Project-URL: Bug Tracker, https://github.com/snowflakedb/snowflake-cli/issues
@@ -222,12 +222,12 @@ Requires-Dist: jinja2==3.1.4
222
222
  Requires-Dist: packaging
223
223
  Requires-Dist: pip
224
224
  Requires-Dist: pluggy==1.5.0
225
- Requires-Dist: pydantic==2.8.2
226
- Requires-Dist: pyyaml==6.0.1
225
+ Requires-Dist: pydantic==2.9.1
226
+ Requires-Dist: pyyaml==6.0.2
227
227
  Requires-Dist: requests==2.32.3
228
228
  Requires-Dist: requirements-parser==0.11.0
229
- Requires-Dist: rich==13.7.1
230
- Requires-Dist: setuptools==74.1.0
229
+ Requires-Dist: rich==13.8.0
230
+ Requires-Dist: setuptools==74.1.2
231
231
  Requires-Dist: snowflake-connector-python[secure-local-storage]==3.12.1
232
232
  Requires-Dist: snowflake-core==0.8.0; python_version < '3.12'
233
233
  Requires-Dist: snowflake-snowpark-python>=1.15.0; python_version < '3.12'
@@ -239,7 +239,7 @@ Requires-Dist: coverage==7.6.1; extra == 'development'
239
239
  Requires-Dist: pre-commit>=3.5.0; extra == 'development'
240
240
  Requires-Dist: pytest-randomly==3.15.0; extra == 'development'
241
241
  Requires-Dist: pytest==8.3.2; extra == 'development'
242
- Requires-Dist: syrupy==4.6.1; extra == 'development'
242
+ Requires-Dist: syrupy==4.7.1; extra == 'development'
243
243
  Description-Content-Type: text/markdown
244
244
 
245
245
  <!--
@@ -1,14 +1,15 @@
1
- snowflake/cli/__about__.py,sha256=p_lpL0rsfFyP7RRb53iSXwYZBbwWN7ayfR_98djruG0,636
1
+ snowflake/cli/__about__.py,sha256=cWSBg7un5oHfcUNd8S8zB7oEqm9LAQhLp0o90yJUDVU,636
2
2
  snowflake/cli/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
3
3
  snowflake/cli/_app/__init__.py,sha256=CR_uTgoqHnU1XdyRhm5iQsS86yWXGVx5Ht7aGSDNFmc,765
4
4
  snowflake/cli/_app/__main__.py,sha256=mHaHr0OsE2H_kUzNE3pu1znAr_stjXTZ4LAp7Hi2_po,834
5
- snowflake/cli/_app/cli_app.py,sha256=93uIlP40ATOQm8kLocswDBb3kI9v5a76_CHIchPY-Gg,8156
5
+ snowflake/cli/_app/cli_app.py,sha256=rC0AKsNhZ45PsT_g1eNiDJUPda8WE-HwHqW16Xle79k,8434
6
6
  snowflake/cli/_app/constants.py,sha256=WCqViioXdOt0Cykf-KK42cBLfqHKTfYobMJJ-AC7kSs,698
7
7
  snowflake/cli/_app/loggers.py,sha256=anPJsFA4H8qV928LTxU_sQ5Ci8MWphFb14GSSBly-XA,6638
8
8
  snowflake/cli/_app/main_typer.py,sha256=v2n7moen3CkP-SfsGrTh-MzFgqG6Ak8bJa8E2dGKzFw,2111
9
9
  snowflake/cli/_app/printing.py,sha256=4e-OlRZcruq6_HaUcTBoYeer9LOg8qF4iHvEvbiRucQ,5820
10
- snowflake/cli/_app/snow_connector.py,sha256=OuSJkm-fhASJ2QmY45JhueyBcjs9fSuoXvmiHbwS-ME,9149
11
- snowflake/cli/_app/telemetry.py,sha256=ly-JfZ5bCoX8hKlHp1qRYOOxfS7MnHXMWQ8U0OddcrU,6366
10
+ snowflake/cli/_app/snow_connector.py,sha256=X_Gvd_2WdS__WHoGuQQpBwjQeZy_8cmeC8n8ji7PkKs,10651
11
+ snowflake/cli/_app/telemetry.py,sha256=bqQpmzwurhc8Mdv7BBL8rCnsf1Mf5UHcUwRhtMja7hY,6424
12
+ snowflake/cli/_app/version_check.py,sha256=6dxv6gCKIpoBehF2tymFx9-a2X0M6J5zgY2uOiyLGSc,2353
12
13
  snowflake/cli/_app/api_impl/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
13
14
  snowflake/cli/_app/api_impl/plugin/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
14
15
  snowflake/cli/_app/api_impl/plugin/plugin_config_provider_impl.py,sha256=QzLbj1eUVdQstrHSitozhgN94r0EHBH6KnzEAReY3Es,2427
@@ -43,7 +44,7 @@ snowflake/cli/_plugins/cortex/manager.py,sha256=ykc5R9g3kPRuib2LlfLV_rkFB6KDJ3k9
43
44
  snowflake/cli/_plugins/cortex/plugin_spec.py,sha256=wbOkXoUTVdXCj8m_-bJRi7IiKxS03q0XEgxrT7aB3yU,995
44
45
  snowflake/cli/_plugins/cortex/types.py,sha256=9KQPlQRkoR67ty8VoqsifJfaoeLJPXZzCJ6dehYWYLE,827
45
46
  snowflake/cli/_plugins/git/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
46
- snowflake/cli/_plugins/git/commands.py,sha256=zIe9iVcCG0IgB3hXabCO2IATA84f0sWh1Kdtb8L4gwo,9939
47
+ snowflake/cli/_plugins/git/commands.py,sha256=4NghBGIhxnETtr7aiy9dsQR7YD-8FR2SWpckihGOshU,11249
47
48
  snowflake/cli/_plugins/git/manager.py,sha256=s9UHhNVGndh7vfrOpMb-5rZfEz6muI9hNmtx8KtrFzI,3888
48
49
  snowflake/cli/_plugins/git/plugin_spec.py,sha256=aadJK8d9Aanwpmktd_eRYwf8OJvN-V8iCHIpjL7AM44,992
49
50
  snowflake/cli/_plugins/init/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
@@ -58,12 +59,13 @@ snowflake/cli/_plugins/nativeapp/constants.py,sha256=j25fS9dS54GPPp41njUOZTDykhY
58
59
  snowflake/cli/_plugins/nativeapp/exceptions.py,sha256=xRqMmFZeJwhViQrfe-T9nQY03_f4b_VKZeb5liv1eis,4374
59
60
  snowflake/cli/_plugins/nativeapp/feature_flags.py,sha256=Y1peJF8ju_lybKjklOvXYsGQMN8VhFoLnoq-Z7oqO-E,829
60
61
  snowflake/cli/_plugins/nativeapp/init.py,sha256=Hg1LojKBtmhhFOMsPvvFd5eBChi6N8sF8PAjKrGXVZ4,12125
61
- snowflake/cli/_plugins/nativeapp/manager.py,sha256=pUN6HQYt60jqLqPbO6loZQ9b23TtuPTZGZ1Quv-Dccs,20135
62
+ snowflake/cli/_plugins/nativeapp/manager.py,sha256=ANsfnnDen_YSTWJyCnekGhq8Cc2hGVCbfDDRpRtbFOQ,18640
62
63
  snowflake/cli/_plugins/nativeapp/plugin_spec.py,sha256=f36DGbQ9716O-2nUCvwmY2RF8hPOkJmr0YsNc3ffu7A,998
63
64
  snowflake/cli/_plugins/nativeapp/policy.py,sha256=yND6QTJUtbuREdT9I2fzFI4-XFd7zbNgWKlvoFICwko,1605
64
65
  snowflake/cli/_plugins/nativeapp/project_model.py,sha256=hFK7z0QL-e8IH8QO3dgESPCY4Rp1mUcoUEFZ43XvmqY,7645
65
- snowflake/cli/_plugins/nativeapp/run_processor.py,sha256=GuF4S7k0A2mRRQWR4d6GFxfFFf2JvwwoONhQczLPBac,16103
66
- snowflake/cli/_plugins/nativeapp/teardown_processor.py,sha256=j-c9LpDojQhC0zUd6UxNqvzRK-pAk368Iz156maZvlI,8927
66
+ snowflake/cli/_plugins/nativeapp/run_processor.py,sha256=vrxeyfFsuodzdYtUXxeX2BGy_Fd9jsCzvNi3tyJcTDo,7423
67
+ snowflake/cli/_plugins/nativeapp/same_account_install_method.py,sha256=-UZHNXwj3mOh5Gm8mOUGnufdmBbH82esr10XLLDeSwo,2396
68
+ snowflake/cli/_plugins/nativeapp/teardown_processor.py,sha256=7YdCJMdRzFkbUCOHmlxDZ9dNEuPh84Z5G2cy2isz5wk,2260
67
69
  snowflake/cli/_plugins/nativeapp/utils.py,sha256=dR7xjjHM8LlyE-PVKhQfAi6OKPd1TA9XQxN5EsBamLI,2867
68
70
  snowflake/cli/_plugins/nativeapp/codegen/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
69
71
  snowflake/cli/_plugins/nativeapp/codegen/artifact_processor.py,sha256=w8u0zf4iQjd1gW2vsqkA3GLcibTbG9vMWTdOLC91Jas,2943
@@ -74,9 +76,9 @@ snowflake/cli/_plugins/nativeapp/codegen/setup/setup_driver.py.source,sha256=wnJ
74
76
  snowflake/cli/_plugins/nativeapp/codegen/snowpark/callback_source.py.jinja,sha256=JiMs2NKhtFFvKotQFU61wpKBAqPAfBthGsdT1aZgY-c,7531
75
77
  snowflake/cli/_plugins/nativeapp/codegen/snowpark/extension_function_utils.py,sha256=BCPxRBiHk_FUEmXPx4AzjHcXq2DUL5BlqFsBVbzDHlo,7627
76
78
  snowflake/cli/_plugins/nativeapp/codegen/snowpark/models.py,sha256=xPC7Igbyo_A6Su4xWeXNYV421uefMqHpQbwFGG8AprI,2225
77
- snowflake/cli/_plugins/nativeapp/codegen/snowpark/python_processor.py,sha256=ESgcBlBIAtbLlig_hAl4NlGHluAxGOmYdOmrCmEvBCw,19854
78
- snowflake/cli/_plugins/nativeapp/codegen/templates/templates_processor.py,sha256=N-SaW_rAVGPBFXf95uwICtd8z_7kFJlaK38LTCakIQM,3504
79
- snowflake/cli/_plugins/nativeapp/v2_conversions/v2_to_v1_decorator.py,sha256=k-UanjXbvQ1GEFpM1F6bM8Uhefos5V23NdeYTbzfVzY,6369
79
+ snowflake/cli/_plugins/nativeapp/codegen/snowpark/python_processor.py,sha256=szKSE0aAm65q3aBkKY5AC4oMi9Fc8fCA7wS30vBTIUI,19824
80
+ snowflake/cli/_plugins/nativeapp/codegen/templates/templates_processor.py,sha256=ZfGd4kc72oWror2C6-TFJBEXCaQKB2ZQdTEKLqafi48,4077
81
+ snowflake/cli/_plugins/nativeapp/v2_conversions/v2_to_v1_decorator.py,sha256=AO60koMSU5gSEb_f_9zGiXMjApIjdC78XUFa5dcwJIg,9958
80
82
  snowflake/cli/_plugins/nativeapp/version/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
81
83
  snowflake/cli/_plugins/nativeapp/version/commands.py,sha256=RWHCrYItkWVL6zAyKsPIhNy86b8-zdbe_dL0FhnXutk,5953
82
84
  snowflake/cli/_plugins/nativeapp/version/version_processor.py,sha256=k2nBgLv4FxH0s7qRxuj5RBd3DItz6NJLZAucsJ85rQE,14817
@@ -93,9 +95,9 @@ snowflake/cli/_plugins/object/common.py,sha256=x1V8fiVnh7ohHHq0_NaGFtUvTz0soVRSG
93
95
  snowflake/cli/_plugins/object/manager.py,sha256=3zddL5hr8IBU5yDdCLrj4m1GEeQUF2RARpxmaYvXilA,3940
94
96
  snowflake/cli/_plugins/object/plugin_spec.py,sha256=O8k6hSD48w4Uhkho0KpcTDkZ2iNjiU5jCPvEVitDzeo,995
95
97
  snowflake/cli/_plugins/snowpark/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
96
- snowflake/cli/_plugins/snowpark/commands.py,sha256=RmKw-M7kGy4HoxUYfIrp07UPfnMEzM63aFVLnmqJpt4,16563
98
+ snowflake/cli/_plugins/snowpark/commands.py,sha256=fmJ9BzuJ-dQx9aEzmI3mofn7e58OTzIWQ8EqV_uOK-w,16589
97
99
  snowflake/cli/_plugins/snowpark/common.py,sha256=RrdogD2kOoITNmsWd_hLyKWQbijQtK4xC1euFUhX_t4,9250
98
- snowflake/cli/_plugins/snowpark/models.py,sha256=XKX5pB9sf0jLPaxXnZVO42Axf6NZla-yp5dm8Ja5-38,4757
100
+ snowflake/cli/_plugins/snowpark/models.py,sha256=Bd69O3krCS5HvQdHhjQsbhFi0wtYOD_Y9sj6lBMR7KU,4766
99
101
  snowflake/cli/_plugins/snowpark/package_utils.py,sha256=D7XhCa2XpFfYBdBDW5qA29ediATjus1w711r8rQgGJ4,12287
100
102
  snowflake/cli/_plugins/snowpark/plugin_spec.py,sha256=2fzlWnGL57oCLWfmkfo6USxvJpy7K9KPE3-ZqwILQcg,997
101
103
  snowflake/cli/_plugins/snowpark/snowpark_project_paths.py,sha256=vy_RdaA_b57P-_pCoUTJric7FZHQgJZbnICQuzw_drw,3640
@@ -134,22 +136,23 @@ snowflake/cli/_plugins/stage/md5.py,sha256=hX_Ao7ys7hUPNuWLm5KEmIpcIULEIJ1UMgc4q
134
136
  snowflake/cli/_plugins/stage/plugin_spec.py,sha256=2APmhjF1Emtdx1Ir9vLwJ1PLgLbnu7Or8lijOi_AM2U,994
135
137
  snowflake/cli/_plugins/stage/utils.py,sha256=Bl9zn4H8sN6k5lsr0oRssLKcuVGnnFZU2Jnj7IOgUaE,1764
136
138
  snowflake/cli/_plugins/streamlit/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
137
- snowflake/cli/_plugins/streamlit/commands.py,sha256=NrnDVXoiVefuwoBuEzMJ2X6ebbsDSmNG8D-5b3-DmAk,5852
138
- snowflake/cli/_plugins/streamlit/manager.py,sha256=3l3rdlw4CtuSb_CcMTj1-b-20u7G8GGhXIGKuDm1Rj8,7955
139
+ snowflake/cli/_plugins/streamlit/commands.py,sha256=Kzy_ILDfOJLhz_BNxvFWnV3W0hY45g_lPY5CY12eZuI,5878
140
+ snowflake/cli/_plugins/streamlit/manager.py,sha256=2DJwBLXrtGLyZE3LB748taxyltXSNBkowfLEYZ8QvXQ,8343
139
141
  snowflake/cli/_plugins/streamlit/plugin_spec.py,sha256=swcszE2JoJWs-DzgN02CxK3myIYexsnWijkFYyYf7Ws,998
140
142
  snowflake/cli/_plugins/workspace/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
141
- snowflake/cli/_plugins/workspace/action_context.py,sha256=-mmGW8IdLVuH4rshPrPznCzw0HGispK2HSmY9q9KzEg,384
142
- snowflake/cli/_plugins/workspace/commands.py,sha256=vfd4iuFJWHlGZfrqMkr5coipmrv5yAt1us-7VURsd0o,6563
143
- snowflake/cli/_plugins/workspace/manager.py,sha256=BfiZMIfHJ48aLRwG3TLQR0AWul_NGFmDw83Ldrp_LcY,3172
143
+ snowflake/cli/_plugins/workspace/action_context.py,sha256=uzCRjyDhfLeh12yMt6vIbml1KeUNaMbZBJWectL6eCU,419
144
+ snowflake/cli/_plugins/workspace/commands.py,sha256=6eV_n3x8JTblsYMHOO_gDb64pLG0YekeIaXw4-4ucjE,7867
145
+ snowflake/cli/_plugins/workspace/manager.py,sha256=gMPxtdW9pl8JYAGz71ylS1oGmyfC4z-4_grCHW01exk,3216
144
146
  snowflake/cli/_plugins/workspace/plugin_spec.py,sha256=lHGP4GK4g-IqHzkRJ--3d8APllrv6Ra13wShWOszXLQ,979
145
147
  snowflake/cli/api/__init__.py,sha256=kD6lYv5et7QJvW7vzvLN9p2ibfD7pjh9KRWsp2QoYqo,1330
146
- snowflake/cli/api/cli_global_context.py,sha256=Cy0gwO6hPV2J80MNgbcpbVg6p1sU_Cc3iq9aH3hbaTc,12560
147
- snowflake/cli/api/config.py,sha256=YN8NVWQ5thYu7yVrJEO1zr1zw16wne4Pt8OyB_7PAr0,11575
148
+ snowflake/cli/api/cli_global_context.py,sha256=CqPbZbqXyA3rU5XVirEdJh-612poL_saG1IzBcMA_TY,8290
149
+ snowflake/cli/api/config.py,sha256=4LpNlrNGnAV-lFj6gyzAh8IJS-tSqKuKikQlYBLqZ7I,11552
150
+ snowflake/cli/api/connections.py,sha256=qiAjFDLK_OIhFaXn-TRmNAIeWAArNWRRp26bjZ7ahXE,7964
148
151
  snowflake/cli/api/constants.py,sha256=v5vixBpFeJRdoUbEY1T43amHNts56Y7VWvoPPclj43s,3233
149
152
  snowflake/cli/api/errno.py,sha256=IvotDJv_m_lz4tf5es0q7qRSdzCxv3zd2X2bQP6KsNU,1015
150
153
  snowflake/cli/api/exceptions.py,sha256=nN9tQFLwFiwD_QriybsIhlfv5SYXBGTNQvhfIt2ZtUI,6257
151
154
  snowflake/cli/api/feature_flags.py,sha256=dtcXEgMebFWpFyPrSBN6HlDKPdnCM9JjwCXSXQsE3VI,1614
152
- snowflake/cli/api/identifiers.py,sha256=-DFZo_SDfoLIYgmLBM9X58p7lfgHpGsDn7lOmgj9BOw,6345
155
+ snowflake/cli/api/identifiers.py,sha256=cmnVJQwY2SVFoCGhbxzvTMytFMBJDTpGaEZyccfmDbg,6462
153
156
  snowflake/cli/api/rest_api.py,sha256=X2hYq-J2mZJmVIEeCUvdk8ccTiV86ltVlj9ac5ZmIak,6070
154
157
  snowflake/cli/api/sanitizers.py,sha256=7EKqVQ3KOob0IFFoc_GmXPYpRhgnmIqhnJSvHPgxM5I,1211
155
158
  snowflake/cli/api/secure_path.py,sha256=h1ZrVyFBzGTisbjTA5vRFYOjRVn-ytM-ShO6XcBgS3M,12909
@@ -161,21 +164,20 @@ snowflake/cli/api/commands/common.py,sha256=6CrJqhQl-Mu0jwFmWyNKvvB7jFQ1EJdnKFW9
161
164
  snowflake/cli/api/commands/decorators.py,sha256=qzCPw9Jh0A9FBOGV8GebV0b5cwdh9bNoNB5dFcbMU8s,10258
162
165
  snowflake/cli/api/commands/execution_metadata.py,sha256=9tz1dbzdVRLFprGi_y8TeTfv36VewFeGdhQX6NfwAXM,1231
163
166
  snowflake/cli/api/commands/experimental_behaviour.py,sha256=HFTw0d46B1QJpiCy0MeeJhWXrPF_bnmgUGaEWkWXw98,733
164
- snowflake/cli/api/commands/flags.py,sha256=HZgDGEoSvT1VSTdxf4NAKs4ws3rBM12XWhbxh0bYelc,17396
167
+ snowflake/cli/api/commands/flags.py,sha256=EOAmniDKQay52yn7IIYUusgk4KozjIzeYxS23sb_6T4,16192
165
168
  snowflake/cli/api/commands/overrideable_parameter.py,sha256=LDiRQudkTeoWu5y_qTCVmtseEvO6U9LuSiuLZt5oFq8,6353
166
- snowflake/cli/api/commands/snow_typer.py,sha256=5s7UCs0x2EInKCCgCACQOalzaCunKem_qfQs2O1_K90,8775
167
- snowflake/cli/api/commands/typer_pre_execute.py,sha256=SliPXOqXRujfQ-csvrFfpSzucoDoO7khZ72ffcTIWls,957
169
+ snowflake/cli/api/commands/snow_typer.py,sha256=_3T8CUtGyuJAOR3XKtQX2XcHcNwxjeAC1UoAAsX7ZBQ,8849
168
170
  snowflake/cli/api/commands/utils.py,sha256=26oSgoVqxG_qkFdHDakqI1TempnY0fJmkinJx_SMjfw,606
169
171
  snowflake/cli/api/console/__init__.py,sha256=jKSsXJDqyQZwJ--5eRzUqb2nNvq-lo_NC1pbqK5xROI,665
170
- snowflake/cli/api/console/abc.py,sha256=o2rEhBkhYXiflP9f6zOUfLZT2JgIcGr_YaOn6x03VmY,2898
172
+ snowflake/cli/api/console/abc.py,sha256=xSE3mlkkyqrqQNeAoZPkA-ji7KKEaz6jgTC_zCVFLSA,2913
171
173
  snowflake/cli/api/console/console.py,sha256=t5p4RTZHFXxofc7Xw1v5HjaNc0n1CXUF8Ox1Z1bRTNc,4573
172
174
  snowflake/cli/api/console/enum.py,sha256=4JyaGjtOqlSsHx2ovgJ9I83KqlWJ9GLhUFTUicSa8RQ,666
173
- snowflake/cli/api/entities/application_entity.py,sha256=gE-z3jQEpHg-pCgVkzW9LS0ohuPDzOkKU1gkvFPBYYs,332
174
- snowflake/cli/api/entities/application_package_entity.py,sha256=809_PyruM4-QVSJ1C_H7S7NmSHbcvtg_E2f3Sl0Y9OY,20772
175
- snowflake/cli/api/entities/common.py,sha256=zORjCTOgmmsYwjAEHixwiOgMwWbriHs7gqTHYEPivfc,1562
175
+ snowflake/cli/api/entities/application_entity.py,sha256=qltAB95HIAEo_otwCQg-GUkDv2K7NgOrOSOQHyTOuKo,27465
176
+ snowflake/cli/api/entities/application_package_entity.py,sha256=QVAix4Mw6HZArmPw5fOwtMyBtx65PUxg9UOFQJgdMfs,24385
177
+ snowflake/cli/api/entities/common.py,sha256=adOs-03HULBmCtFWmTt6lXsda435CA5C-9MO79H4XkI,1595
176
178
  snowflake/cli/api/entities/snowpark_entity.py,sha256=Mk-gXKxsVqu3a62mKjQzL7phSsak9WiJZXD2IvEduws,511
177
179
  snowflake/cli/api/entities/streamlit_entity.py,sha256=Rtm3MjXOrkv5Ktk4iZgdgyQcqCQrZHBfKLj-1Z-eIX4,271
178
- snowflake/cli/api/entities/utils.py,sha256=U1r6wrcgyOm0R1pjX9uDl5LHgsSyYhtRuOiYi8_Ttow,13280
180
+ snowflake/cli/api/entities/utils.py,sha256=h-NVaS95rhh4K6qogSH8fduEQNeOHR3kUJ7CA4BANOg,13877
179
181
  snowflake/cli/api/output/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
180
182
  snowflake/cli/api/output/formats.py,sha256=L1As7qBQSZ7elG6Y8vRqFpljpjJgRr6fjIu6re5r0MM,667
181
183
  snowflake/cli/api/output/types.py,sha256=pzBlAr_ubLk810ii35t3hDUn1QsOFLg2yKyVkuYvA5o,3281
@@ -184,21 +186,21 @@ snowflake/cli/api/plugins/plugin_config.py,sha256=oJB3HvVqw7R-MDh5jGJtL84ABOATsF
184
186
  snowflake/cli/api/plugins/command/__init__.py,sha256=qCzBzpq8__2OUN0PcruIKgQXI2V9rzk4UIGVLFv7yk4,2134
185
187
  snowflake/cli/api/plugins/command/plugin_hook_specs.py,sha256=AHJGk6j3NRzalIe4llM3Mt0-opHui1sLdbILoEMhpuA,714
186
188
  snowflake/cli/api/project/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
187
- snowflake/cli/api/project/definition.py,sha256=B1tFetzUAsH8lsWzE69ty2Mn7mutvGq-2Soe1WxnTTo,3928
188
- snowflake/cli/api/project/definition_conversion.py,sha256=aG2KZi9hNWnV0COuM6Q7DXJUfLxsgCVrgf4yX1WpH_s,6569
189
+ snowflake/cli/api/project/definition.py,sha256=5vhSH97v48rWyk7vWGxWngpsEcgJ9-8IX1SYzGYwrUg,4333
190
+ snowflake/cli/api/project/definition_conversion.py,sha256=xAX1mRw1WpcbHiKyQK72qFErwJqxUuW-itCWp57vDwo,13173
189
191
  snowflake/cli/api/project/definition_manager.py,sha256=mquz4lDFUtlrlSTpmMVesX3nrJouDdO0slRgCLDeQrU,4985
190
192
  snowflake/cli/api/project/errors.py,sha256=9TGN2ezqSCHmSGy1U7AByaJm5Xf47zN-7N3i6R6fyBg,2136
191
193
  snowflake/cli/api/project/project_verification.py,sha256=smprjxJZlqqIPYuyf6a3OJitRpn8Ru6tAoZB-DdEz1s,990
192
194
  snowflake/cli/api/project/util.py,sha256=eOJbXx4CZ7DfmHI4-CJT0cV7lP8DH0gI9JTBic7-xNs,9639
193
195
  snowflake/cli/api/project/schemas/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
194
- snowflake/cli/api/project/schemas/identifier_model.py,sha256=hV9_wTnp1Ed8rHll4ryXC4VfiKZT35lch4JN_X6fz1c,2110
195
- snowflake/cli/api/project/schemas/project_definition.py,sha256=NoE3a0Ki-DutMQoz-CxMllwTRTXOJYoouchtbPiUp1o,9747
196
+ snowflake/cli/api/project/schemas/identifier_model.py,sha256=lv8h7mgWepRare-JKT3fL4APG9QXY6_o6ZhG1P2ZizE,2130
197
+ snowflake/cli/api/project/schemas/project_definition.py,sha256=-K2lRM0DXmzjASs_fUwkNAimkYJMpVeq3tluG4Eo48g,11560
196
198
  snowflake/cli/api/project/schemas/template.py,sha256=w8cJt6VcMmMJgKO6rv31cTBDQZuSsaMVOOfeBZMF56k,3019
197
199
  snowflake/cli/api/project/schemas/updatable_model.py,sha256=h7k6TOcrTcNf0w-Pnmww2D_rtI3m_z07CWg8-NHgbmU,7604
198
200
  snowflake/cli/api/project/schemas/entities/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
199
201
  snowflake/cli/api/project/schemas/entities/application_entity_model.py,sha256=3kEpJ5SMz37nTxldTOBd_C6eYbCU60uJ_yFqV6KgPsE,2115
200
202
  snowflake/cli/api/project/schemas/entities/application_package_entity_model.py,sha256=u55NzC1mgfA0OgsPKR_TSRY4TGByykykpJhPcTxxlwM,3747
201
- snowflake/cli/api/project/schemas/entities/common.py,sha256=AqYUSGfYXHQ5Ud7OzxVZxHMPvhkKkGF-GqObpYDf_S0,5018
203
+ snowflake/cli/api/project/schemas/entities/common.py,sha256=eHKq7IcNFoKSJPDlAvwM-lavDYHzabyPs6axfUiGisM,4780
202
204
  snowflake/cli/api/project/schemas/entities/entities.py,sha256=uAGrk0bO3gHoqNNDBK077LqtYIc2ro3iZ3ULII0pn20,2074
203
205
  snowflake/cli/api/project/schemas/entities/snowpark_entity.py,sha256=ZAQC3JkSzOrGK-SPrKfDglbZydj83Z-Gi1hw8gCX42Y,6309
204
206
  snowflake/cli/api/project/schemas/entities/streamlit_entity_model.py,sha256=LVeqWUfEyI7sOVelrVvEkyVFnWTEGctWY_H1WqT5jsc,2586
@@ -215,12 +217,12 @@ snowflake/cli/api/project/schemas/streamlit/__init__.py,sha256=uGA_QRGW3iGwaegpF
215
217
  snowflake/cli/api/project/schemas/streamlit/streamlit.py,sha256=VXOYFJPwO8e3NaPBkcWhCaPGof18XH4TYKEMaqu2UYQ,1873
216
218
  snowflake/cli/api/rendering/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
217
219
  snowflake/cli/api/rendering/jinja.py,sha256=gpHUJmgiFx8iDJFy0DgsdtBHY2k95pY9kbW51Z2VYKM,3726
218
- snowflake/cli/api/rendering/project_definition_templates.py,sha256=QdF7Fc7NcYRwwgQP8-c1JAQrxOVjFG7cKpEuCRHf0JU,1342
220
+ snowflake/cli/api/rendering/project_definition_templates.py,sha256=RzVmw7JwLoeBntgLNIG4QESqKGr1i2K3XivFszqWby8,1457
219
221
  snowflake/cli/api/rendering/project_templates.py,sha256=zRh863Gn2hYli9uUu1eXQ_gZsMDUCCg5N44kcPXcSSg,3474
220
- snowflake/cli/api/rendering/sql_templates.py,sha256=C2Sjht3AJLmMv17yPlSzE-s3l2mAvv8Onn0RefgetVc,3630
222
+ snowflake/cli/api/rendering/sql_templates.py,sha256=Tu4evKhzi02sJY9jYWPcid_nlA8_Z9cFRt-Dv9-ucsA,3808
221
223
  snowflake/cli/api/utils/__init__.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh9ou8J439uU,578
222
224
  snowflake/cli/api/utils/cursor.py,sha256=JlyUG5b4EXii71Dm7qiTdptjwIsOOmEv2QmZA1cY8NQ,1222
223
- snowflake/cli/api/utils/definition_rendering.py,sha256=2yssptDooDEwKEHnsgApBKZ5jLXs9mSwWmBZLgoCVLY,15188
225
+ snowflake/cli/api/utils/definition_rendering.py,sha256=e3TAMELQ5vGaIYoB7wgObIJUiNob-MIwfD7iVl9-3JE,15225
224
226
  snowflake/cli/api/utils/dict_utils.py,sha256=8vb9EyiT8gNHCtPNfE1S-0WcWdP6G_kiwJ-aizu3Pzs,2799
225
227
  snowflake/cli/api/utils/error_handling.py,sha256=etIGdS8kd9APgyeUecnY2XMivDORSRV8q-WuBtpriZY,708
226
228
  snowflake/cli/api/utils/graph.py,sha256=XZgcTySyS1je9ARdPWqJyrfzuqFBNt9SSLnGeE2na8M,3045
@@ -229,8 +231,8 @@ snowflake/cli/api/utils/naming_utils.py,sha256=uGA_QRGW3iGwaegpFsLgOhup0zBliBSXh
229
231
  snowflake/cli/api/utils/path_utils.py,sha256=ru0jgw6Ur5zhqpHhj_eAqcaJdrgEgr3bC7Z02FnQV18,1218
230
232
  snowflake/cli/api/utils/templating_functions.py,sha256=DlmpGAEY6OBArtIap6kN1aaILPwx2ynqKflPwjj7BbU,4935
231
233
  snowflake/cli/api/utils/types.py,sha256=fVKuls8axKSsBzPqWwrkwkwoXXmedqxNJKqfXrrGyBM,1190
232
- snowflake_cli_labs-3.0.0rc1.dist-info/METADATA,sha256=8TSgsQlujB1XUiseI_WxlyC1v_1GO9Q-ogOGnkdrrzM,17916
233
- snowflake_cli_labs-3.0.0rc1.dist-info/WHEEL,sha256=1yFddiXMmvYK7QYTqtRNtX66WJ0Mz8PYEiEUoOUUxRY,87
234
- snowflake_cli_labs-3.0.0rc1.dist-info/entry_points.txt,sha256=6QmSI0wUX6p7f-dGvrPdswlQyVAVGi1AtOUbE8X6bho,58
235
- snowflake_cli_labs-3.0.0rc1.dist-info/licenses/LICENSE,sha256=mJMA3Uz2AbjU_kVggo1CAx01XhBsI7BSi2H7ggUg_-c,11344
236
- snowflake_cli_labs-3.0.0rc1.dist-info/RECORD,,
234
+ snowflake_cli_labs-3.0.0rc2.dist-info/METADATA,sha256=baLTYbY4wgCmA238mmKMmBrR02zxyz4W-LtQHrpipZ4,17916
235
+ snowflake_cli_labs-3.0.0rc2.dist-info/WHEEL,sha256=1yFddiXMmvYK7QYTqtRNtX66WJ0Mz8PYEiEUoOUUxRY,87
236
+ snowflake_cli_labs-3.0.0rc2.dist-info/entry_points.txt,sha256=6QmSI0wUX6p7f-dGvrPdswlQyVAVGi1AtOUbE8X6bho,58
237
+ snowflake_cli_labs-3.0.0rc2.dist-info/licenses/LICENSE,sha256=mJMA3Uz2AbjU_kVggo1CAx01XhBsI7BSi2H7ggUg_-c,11344
238
+ snowflake_cli_labs-3.0.0rc2.dist-info/RECORD,,
@@ -1,26 +0,0 @@
1
- # Copyright (c) 2024 Snowflake Inc.
2
- #
3
- # Licensed under the Apache License, Version 2.0 (the "License");
4
- # you may not use this file except in compliance with the License.
5
- # You may obtain a copy of the License at
6
- #
7
- # http://www.apache.org/licenses/LICENSE-2.0
8
- #
9
- # Unless required by applicable law or agreed to in writing, software
10
- # distributed under the License is distributed on an "AS IS" BASIS,
11
- # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
- # See the License for the specific language governing permissions and
13
- # limitations under the License.
14
-
15
- from typing import Callable
16
-
17
- from snowflake.cli.api.cli_global_context import get_cli_context_manager
18
-
19
-
20
- def register_pre_execute_command(command: Callable[[], None]) -> None:
21
- get_cli_context_manager().add_typer_pre_execute_commands(command)
22
-
23
-
24
- def run_pre_execute_commands() -> None:
25
- for command in get_cli_context_manager().typer_pre_execute_commands:
26
- command()