Skip to content

Commit 7ad60a3

Browse files
committed
fix: default sync --express to false, add to sync help
Default express to false for sync (same as deploy) until public announcement. Added TODO to flip default after announcement. Also add express to sync help text grouping.
1 parent b2f7c29 commit 7ad60a3

3 files changed

Lines changed: 7 additions & 5 deletions

File tree

samcli/commands/sync/command.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,11 +163,12 @@
163163
)
164164
@click.option(
165165
"--express/--no-express",
166-
default=True,
166+
default=False,
167167
required=False,
168168
is_flag=True,
169+
# TODO: Flip default to True after public announcement of express mode support
169170
help="Use CloudFormation Express mode to speed up infrastructure deployments by completing once resource "
170-
"configuration is applied, without waiting for full stabilization. Enabled by default.",
171+
"configuration is applied, without waiting for full stabilization.",
171172
)
172173
@container_env_var_file_option(cls=ContainerOptions)
173174
@watch_exclude_option
@@ -307,7 +308,7 @@ def do_cli(
307308
build_in_source: Optional[bool],
308309
watch_exclude: Optional[Dict[str, List[str]]],
309310
language_extensions: Optional[bool],
310-
express: bool = True,
311+
express: bool = False,
311312
) -> None:
312313
"""
313314
Implementation of the ``cli`` method

samcli/commands/sync/core/options.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
ADDITIONAL_OPTIONS: List[str] = [
3636
"watch",
3737
"code",
38+
"express",
3839
"skip_deploy_sync",
3940
"dependency_layer",
4041
"use_container",

tests/unit/commands/sync/test_command.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ def test_infra_must_succeed_sync(
223223
on_failure=None,
224224
max_wait_duration=60,
225225
language_extensions=None,
226-
express=True,
226+
express=False,
227227
)
228228

229229
execute_infra_mock.assert_called_with(
@@ -392,7 +392,7 @@ def test_watch_must_succeed_sync(
392392
on_failure=None,
393393
max_wait_duration=60,
394394
language_extensions=None,
395-
express=True,
395+
express=False,
396396
)
397397
execute_watch_mock.assert_called_once_with(
398398
template=self.template_file,

0 commit comments

Comments
 (0)