pulumi/pkg/cmd/pulumi
Thomas Gummerer e743503d37
state move: show full set of delete commands when writing source stack fails (#17205)
Before actually writing the source stack, we have no way of knowing we
can write it. The same is true for writing the destination stack. This
means if the one we write later fails to write, we get an incompletely
moved state.

We've decided to move the destination stack first, and then the source
stack, so resources are always tracked. The error message also mentions
cleaning up the source stack, however it's not completely obvious how to
do that. Since we know the resources that were supposed to be moved (and
successfully been written to the destination stack at this point), we
can give the user better instructions on how to clean up the resources.

Do that by giving them a full set of `pulumi state delete` commands they
can run to clean up the source stack.

Fixes https://github.com/pulumi/pulumi/issues/17187
2024-09-09 16:33:07 +00:00
..
convert_testdata Refactor convert command to add entrypoint for pulumi convert debugging 2022-10-01 15:40:17 -07:00
pcl_convert_testdata Support PCL as a convert input (and output) 2022-11-11 10:45:40 +00:00
testdata policy publish: default to default-org if possible (#14090) 2023-10-05 16:51:06 +00:00
about.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
about_env.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
about_test.go Move about information to language plugins (#10392) 2022-08-15 14:55:04 +01:00
ai.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
ai_web.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
cancel.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
config.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
config_env.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
config_env_add.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
config_env_add_test.go Fix TestConfigEnvXXX flakes (#16496) 2024-06-27 03:48:41 +00:00
config_env_init.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
config_env_init_test.go Fix TestConfigEnvXXX flakes (#16496) 2024-06-27 03:48:41 +00:00
config_env_ls.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
config_env_ls_test.go Fix TestConfigEnvXXX flakes (#16496) 2024-06-27 03:48:41 +00:00
config_env_rm.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
config_env_rm_test.go Fix TestConfigEnvXXX flakes (#16496) 2024-06-27 03:48:41 +00:00
config_env_test.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
config_test.go Lift context parameter for ApplyProjectConfig (#16012) 2024-04-22 06:37:34 +00:00
console.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
convert-trace.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
convert.go implement the engine bits for debugging support (#17072) 2024-08-30 10:31:28 +00:00
convert_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
crypto.go Fix TestDestroySetsEncryptionsalt test and resulting bug (#15432) 2024-02-15 09:33:27 +00:00
deployment_run.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
deployment_settings_config.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
deployment_settings_config_test.go Do not rely on auto api for cloning repos on ds tests (#17071) 2024-08-27 15:41:31 +00:00
deployment_settings_ops.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
deployment_settings_utils.go Add deployment settings tests, cleanup and better handling of non interactive sessions (#16677) 2024-07-30 19:21:26 +00:00
deployment_settings_utils_test.go Do not rely on auto api for cloning repos on ds tests (#17071) 2024-08-27 15:41:31 +00:00
destroy.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
doc.go Document Go packages (#6009) 2021-01-11 11:07:59 -07:00
env.go Use esc/workspace.DefaultPulumiWorkspace in env cmd (#17104) 2024-08-29 13:08:04 +00:00
errors.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
flags_test.go Set the --continue-on-error flag with PULUMI_CONTINUE_ON_ERROR environment variable (#16442) 2024-06-25 08:28:37 +00:00
gen_completion.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
gen_markdown.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
import.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
import_test.go Add a missing test for the import system (#15664) 2024-03-13 14:13:36 +00:00
install.go implement the engine bits for debugging support (#17072) 2024-08-30 10:31:28 +00:00
login.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
logout.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
logs.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
logs_test.go Use `assert.NoError` rather than `assert.Nil` (#14233) 2023-10-13 09:46:07 +00:00
main.go Sync panic error message with similar messages (#17184) 2024-09-06 09:03:47 +00:00
new.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
new_acceptance_test.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
new_ai.go upgrade to latest version of golangci-lint (#15977) 2024-04-19 06:20:33 +00:00
new_ai_test.go Fix AI prompt repetition on Windows (#15010) 2024-01-03 23:03:11 +00:00
new_test.go Replace pkg/errors.Wrap with fmt.Errorf (#17201) 2024-09-09 11:11:46 +00:00
org.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
org_search.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
org_search_ai.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
org_search_ai_test.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
org_search_test.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
package.go implement the engine bits for debugging support (#17072) 2024-08-30 10:31:28 +00:00
package_add.go Correctly case Python package names in `package add` link instructions (#17178) 2024-09-05 17:27:03 +00:00
package_extract_mapping.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
package_extract_schema.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
package_gen_sdk.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
package_pack_sdk.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
package_publish.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
plugin.go Fix GetPluginInfo with shimless project plugins (#17115) 2024-08-30 15:51:15 +00:00
plugin_install.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
plugin_install_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
plugin_ls.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
plugin_rm.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
plugin_run.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
policy.go [breaking] Changing the version of go.mod in sdk / pkg to be v3 2021-04-14 19:32:18 +01:00
policy_disable.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
policy_enable.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
policy_group_ls.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
policy_ls.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
policy_new.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
policy_new_acceptance_test.go Use context.Background in tests (#14029) 2023-09-25 12:25:26 +00:00
policy_new_test.go Use context.Background in tests (#14029) 2023-09-25 12:25:26 +00:00
policy_publish.go Move GetCloudInsecure to pkg workspace (#17112) 2024-08-30 14:19:07 +00:00
policy_publish_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
policy_rm.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
policy_validate.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
preview.go debugging: more consistency for naming (#17152) 2024-09-04 10:36:45 +00:00
preview_test.go Fix hang in --preview-file (#15203) 2024-01-25 18:03:38 +00:00
pulumi.go Switch back to `os/user` to get the current user (#17125) 2024-08-31 18:54:35 +00:00
pulumi_test.go correct version check when we have a dev version installed (#14954) 2023-12-22 16:40:12 +00:00
query.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
refresh.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
replay_events.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
schema.go [codegen/schema] Add a schema checker (#7865) 2021-08-30 19:29:24 -07:00
schema_check.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
stack.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_change_secrets_provider.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_change_secrets_provider_test.go Lift context parameter to SerializeDeployment/Resource/Operations/Properties (#15929) 2024-04-15 07:45:46 +00:00
stack_export.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_graph.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_graph_test.go Adds a flag to graph command to insert fragment (#14858) 2024-01-08 22:03:08 +00:00
stack_history.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
stack_import.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_init.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
stack_init_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
stack_ls.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
stack_ls_test.go [test] fix `TestCreatingProjectWithEmptyConfig` flakiness (#14777) 2023-12-08 23:00:49 +00:00
stack_output.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_output_fuzz_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
stack_output_test.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_rename.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_rm.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_select.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
stack_tag.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
stack_test.go Show a fully qualified stack name in `pulumi stack --show-name -Q` (#16453) 2024-06-26 09:00:22 +00:00
stack_unselect.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
state.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
state_delete.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
state_edit.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
state_edit_encoder.go Lift context parameter to SerializeDeployment/Resource/Operations/Properties (#15929) 2024-04-15 07:45:46 +00:00
state_edit_test.go Fix context in state edit command (#15354) 2024-02-07 09:01:56 +00:00
state_move.go state move: show full set of delete commands when writing source stack fails (#17205) 2024-09-09 16:33:07 +00:00
state_move_test.go state move: show full set of delete commands when writing source stack fails (#17205) 2024-09-09 16:33:07 +00:00
state_rename.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
state_rename_test.go Allow anything in resource names (#14107) 2023-11-20 08:59:00 +00:00
state_unprotect.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
state_upgrade.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
state_upgrade_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00
terminal.go crypto/ssh/terminal is deprecated 2023-01-12 09:07:34 -08:00
terminal_test.go Fix negative page size panic (#10475) 2022-08-23 16:45:47 -04:00
up.go debugging: more consistency for naming (#17152) 2024-09-04 10:36:45 +00:00
up_test.go all: Reformat with gofumpt 2023-03-03 09:00:24 -08:00
util.go Move GetCloudInsecure to pkg workspace (#17112) 2024-08-30 14:19:07 +00:00
util_remote.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
util_remote_test.go [cli] Experimental support for remote operations 2022-10-27 16:15:59 -07:00
util_test.go chore: fix function names in comment (#16044) 2024-04-24 06:23:35 +00:00
version.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
view-trace.go Centralise human-friendly error handling in the CLI (#17046) 2024-08-23 08:48:42 +00:00
watch.go Lift pkgWorkspace.Instance to top level command functions (#17103) 2024-08-29 13:12:16 +00:00
whoami.go Move GetCurrentCloudURL to pkg workspace (#17107) 2024-08-30 11:58:09 +00:00
whoami_test.go Enable goheader rule and add missing license headers (#15473) 2024-09-09 12:05:45 +00:00