@aws-cdk/integ-runner 2.197.22 → 2.197.24

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.
@@ -1345,6 +1345,13 @@ var init_interfaces = __esm({
1345
1345
  }
1346
1346
  });
1347
1347
 
1348
+ // ../cloud-assembly-schema/lib/cloud-assembly/validation-report-schema.ts
1349
+ var init_validation_report_schema = __esm({
1350
+ "../cloud-assembly-schema/lib/cloud-assembly/validation-report-schema.ts"() {
1351
+ "use strict";
1352
+ }
1353
+ });
1354
+
1348
1355
  // ../cloud-assembly-schema/lib/cloud-assembly/index.ts
1349
1356
  var cloud_assembly_exports = {};
1350
1357
  __export(cloud_assembly_exports, {
@@ -1362,6 +1369,7 @@ var init_cloud_assembly = __esm({
1362
1369
  init_artifact_schema();
1363
1370
  init_context_queries();
1364
1371
  init_interfaces();
1372
+ init_validation_report_schema();
1365
1373
  }
1366
1374
  });
1367
1375
 
@@ -4723,7 +4731,7 @@ var require_semver2 = __commonJS({
4723
4731
  // ../cloud-assembly-schema/cli-version.json
4724
4732
  var require_cli_version = __commonJS({
4725
4733
  "../cloud-assembly-schema/cli-version.json"(exports2, module2) {
4726
- module2.exports = { version: "2.1123.0" };
4734
+ module2.exports = { version: "2.1124.1" };
4727
4735
  }
4728
4736
  });
4729
4737
 
@@ -6756,6 +6764,175 @@ var require_integ_schema = __commonJS({
6756
6764
  }
6757
6765
  });
6758
6766
 
6767
+ // ../cloud-assembly-schema/schema/validation-report.schema.json
6768
+ var require_validation_report_schema = __commonJS({
6769
+ "../cloud-assembly-schema/schema/validation-report.schema.json"(exports2, module2) {
6770
+ module2.exports = {
6771
+ $ref: "#/definitions/PolicyValidationReportJson",
6772
+ definitions: {
6773
+ PolicyValidationReportJson: {
6774
+ description: "The top-level structure of the policy validation report file.",
6775
+ type: "object",
6776
+ properties: {
6777
+ version: {
6778
+ description: "Protocol version",
6779
+ type: "string"
6780
+ },
6781
+ title: {
6782
+ description: "Report title, if present.",
6783
+ type: "string"
6784
+ },
6785
+ pluginReports: {
6786
+ description: "Reports from all validation plugins that ran during synthesis.",
6787
+ type: "array",
6788
+ items: {
6789
+ $ref: "#/definitions/PluginReportJson"
6790
+ }
6791
+ }
6792
+ },
6793
+ required: ["version", "pluginReports"]
6794
+ },
6795
+ PluginReportJson: {
6796
+ description: "A report from a single validation plugin.",
6797
+ type: "object",
6798
+ properties: {
6799
+ pluginName: {
6800
+ description: "The name of the plugin that produced this report.",
6801
+ type: "string"
6802
+ },
6803
+ pluginVersion: {
6804
+ description: "Version of the plugin that produced this report.",
6805
+ type: "string"
6806
+ },
6807
+ conclusion: {
6808
+ description: "Whether the plugin's validation passed or failed.",
6809
+ $ref: "#/definitions/PolicyValidationReportConclusion"
6810
+ },
6811
+ metadata: {
6812
+ description: "Additional plugin-specific metadata.",
6813
+ type: "object",
6814
+ additionalProperties: {
6815
+ type: "string"
6816
+ }
6817
+ },
6818
+ violations: {
6819
+ description: "Violations found by this plugin.",
6820
+ type: "array",
6821
+ items: {
6822
+ $ref: "#/definitions/PolicyViolationJson"
6823
+ }
6824
+ }
6825
+ },
6826
+ required: ["pluginName", "conclusion", "violations"]
6827
+ },
6828
+ PolicyValidationReportConclusion: {
6829
+ description: "The final conclusion of a validation report.",
6830
+ type: "string",
6831
+ enum: ["success", "failure"]
6832
+ },
6833
+ PolicyViolationJson: {
6834
+ description: "A single policy violation found by a validation plugin.",
6835
+ type: "object",
6836
+ properties: {
6837
+ ruleName: {
6838
+ description: "The name of the rule that was violated.",
6839
+ type: "string"
6840
+ },
6841
+ description: {
6842
+ description: "A description of the violation.",
6843
+ type: "string"
6844
+ },
6845
+ suggestedFix: {
6846
+ description: "How to fix the violation.",
6847
+ type: "string"
6848
+ },
6849
+ severity: {
6850
+ description: "The severity of the violation.",
6851
+ $ref: "#/definitions/PolicyViolationSeverity"
6852
+ },
6853
+ customSeverity: {
6854
+ description: "If the plugin wants to report using a non-standard severity, put it here.",
6855
+ type: "string"
6856
+ },
6857
+ ruleMetadata: {
6858
+ description: "Additional rule-specific metadata.",
6859
+ type: "object",
6860
+ additionalProperties: {
6861
+ type: "string"
6862
+ }
6863
+ },
6864
+ violatingConstructs: {
6865
+ description: "Constructs that violated the rule.",
6866
+ type: "array",
6867
+ items: {
6868
+ $ref: "#/definitions/ViolatingConstructJson"
6869
+ }
6870
+ }
6871
+ },
6872
+ required: ["ruleName", "description", "severity", "violatingConstructs"]
6873
+ },
6874
+ PolicyViolationSeverity: {
6875
+ description: "The severity of a policy violation.",
6876
+ type: "string",
6877
+ enum: ["fatal", "error", "warning", "info", "custom"]
6878
+ },
6879
+ ViolatingConstructJson: {
6880
+ description: "A construct that violated a policy rule.",
6881
+ type: "object",
6882
+ properties: {
6883
+ constructPath: {
6884
+ description: "The construct path as defined in the application.",
6885
+ type: "string"
6886
+ },
6887
+ constructFqn: {
6888
+ description: "The fully qualified name of the construct class (includes the library name).",
6889
+ type: "string"
6890
+ },
6891
+ libraryVersion: {
6892
+ description: "The version of the library that contains this construct.",
6893
+ type: "string"
6894
+ },
6895
+ cloudFormationResource: {
6896
+ description: "If this construct violation regards a CloudFormation resource, a reference to the resource details.",
6897
+ $ref: "#/definitions/CloudFormationResourceJson"
6898
+ },
6899
+ stackTraces: {
6900
+ description: "Stack traces associated with this violation.",
6901
+ type: "array",
6902
+ items: {
6903
+ type: "string"
6904
+ }
6905
+ }
6906
+ },
6907
+ required: ["constructPath"]
6908
+ },
6909
+ CloudFormationResourceJson: {
6910
+ description: "CloudFormation resource details for a violating construct.",
6911
+ type: "object",
6912
+ properties: {
6913
+ templatePath: {
6914
+ description: "The path to the CloudFormation template containing this resource.",
6915
+ type: "string"
6916
+ },
6917
+ logicalId: {
6918
+ description: "The logical ID of the resource in the CloudFormation template.",
6919
+ type: "string"
6920
+ },
6921
+ propertyPaths: {
6922
+ description: "Properties within the construct where the violation was detected.",
6923
+ type: "array",
6924
+ items: {
6925
+ type: "string"
6926
+ }
6927
+ }
6928
+ },
6929
+ required: ["templatePath", "logicalId"]
6930
+ }
6931
+ }
6932
+ };
6933
+ }
6934
+ });
6935
+
6759
6936
  // ../cloud-assembly-schema/schema/version.json
6760
6937
  var require_version = __commonJS({
6761
6938
  "../cloud-assembly-schema/schema/version.json"(exports2, module2) {
@@ -6776,7 +6953,7 @@ __export(manifest_exports, {
6776
6953
  function stripEnumErrors(errors) {
6777
6954
  return errors.filter((e32) => typeof e32.schema === "string" || !("enum" in e32.schema));
6778
6955
  }
6779
- var fs, jsonschema, semver, VERSION_MISMATCH, CLI_VERSION, ASSETS_SCHEMA, ASSEMBLY_SCHEMA, INTEG_SCHEMA, SCHEMA_VERSION, Manifest;
6956
+ var fs, jsonschema, semver, VERSION_MISMATCH, CLI_VERSION, ASSETS_SCHEMA, ASSEMBLY_SCHEMA, INTEG_SCHEMA, VALIDATION_REPORT_SCHEMA, SCHEMA_VERSION, Manifest;
6780
6957
  var init_manifest = __esm({
6781
6958
  "../cloud-assembly-schema/lib/manifest.ts"() {
6782
6959
  "use strict";
@@ -6789,6 +6966,7 @@ var init_manifest = __esm({
6789
6966
  ASSETS_SCHEMA = require_assets_schema();
6790
6967
  ASSEMBLY_SCHEMA = require_cloud_assembly_schema();
6791
6968
  INTEG_SCHEMA = require_integ_schema();
6969
+ VALIDATION_REPORT_SCHEMA = require_validation_report_schema();
6792
6970
  SCHEMA_VERSION = require_version();
6793
6971
  Manifest = class _Manifest {
6794
6972
  static {
@@ -6849,6 +7027,14 @@ var init_manifest = __esm({
6849
7027
  testCases: manifest.testCases ?? []
6850
7028
  };
6851
7029
  }
7030
+ /**
7031
+ * Load and validate the policy validation report from file.
7032
+ *
7033
+ * @param filePath - path to the validation report file.
7034
+ */
7035
+ static loadValidationReport(filePath) {
7036
+ return _Manifest.loadManifest(filePath, VALIDATION_REPORT_SCHEMA);
7037
+ }
6852
7038
  /**
6853
7039
  * Fetch the current schema version number.
6854
7040
  */
@@ -128188,11 +128374,11 @@ var require_randomUUID = __commonJS({
128188
128374
  var require_dist_cjs40 = __commonJS({
128189
128375
  "../../../node_modules/@smithy/uuid/dist-cjs/index.js"(exports2) {
128190
128376
  "use strict";
128191
- var randomUUID8 = require_randomUUID();
128377
+ var randomUUID9 = require_randomUUID();
128192
128378
  var decimalToHex6 = Array.from({ length: 256 }, (_2, i32) => i32.toString(16).padStart(2, "0"));
128193
128379
  var v46 = /* @__PURE__ */ __name(() => {
128194
- if (randomUUID8.randomUUID) {
128195
- return randomUUID8.randomUUID();
128380
+ if (randomUUID9.randomUUID) {
128381
+ return randomUUID9.randomUUID();
128196
128382
  }
128197
128383
  const rnds = new Uint8Array(16);
128198
128384
  crypto.getRandomValues(rnds);
@@ -415523,11 +415709,6 @@ async function getNestedStackArn(nestedStackLogicalId, listStackResources) {
415523
415709
  function isCdkManagedNestedStack(stackResource) {
415524
415710
  return stackResource.Type === "AWS::CloudFormation::Stack" && stackResource.Metadata && stackResource.Metadata["aws:asset:path"];
415525
415711
  }
415526
- function templateContainsNestedStacks(template) {
415527
- return Object.values(template?.Resources ?? {}).some(
415528
- (resource) => resource.Type === "AWS::CloudFormation::Stack"
415529
- );
415530
- }
415531
415712
  var path23, fs25;
415532
415713
  var init_nested_stack_helpers = __esm({
415533
415714
  "../toolkit-lib/lib/api/cloudformation/nested-stack-helpers.ts"() {
@@ -415544,7 +415725,6 @@ var init_nested_stack_helpers = __esm({
415544
415725
  __name(getNestedStackTemplates, "getNestedStackTemplates");
415545
415726
  __name(getNestedStackArn, "getNestedStackArn");
415546
415727
  __name(isCdkManagedNestedStack, "isCdkManagedNestedStack");
415547
- __name(templateContainsNestedStacks, "templateContainsNestedStacks");
415548
415728
  }
415549
415729
  });
415550
415730
 
@@ -416433,13 +416613,13 @@ async function waitFor(valueProvider, timeout = 5e3) {
416433
416613
  async function waitForChangeSet(cfn, ioHelper, stackNameOrArn, changeSetNameOrArn, { fetchAll, diagnoser }) {
416434
416614
  const stackDisplayName = stackNameFromArn(stackNameOrArn);
416435
416615
  const changeSetDisplayName = changeSetNameFromArn(changeSetNameOrArn);
416436
- await ioHelper.defaults.debug((0, import_util30.format)("Waiting for changeset %s on stack %s to finish creating...", changeSetDisplayName, stackDisplayName));
416616
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Waiting for changeset %s on stack %s to finish creating...", changeSetDisplayName, stackDisplayName));
416437
416617
  const ret = await waitFor(async () => {
416438
416618
  const description = await describeChangeSet(cfn, stackNameOrArn, changeSetNameOrArn, {
416439
416619
  fetchAll
416440
416620
  });
416441
416621
  if (description.Status === "CREATE_PENDING" || description.Status === "CREATE_IN_PROGRESS") {
416442
- await ioHelper.defaults.debug((0, import_util30.format)("Changeset %s on stack %s is still creating", changeSetDisplayName, stackDisplayName));
416622
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Changeset %s on stack %s is still creating", changeSetDisplayName, stackDisplayName));
416443
416623
  return void 0;
416444
416624
  }
416445
416625
  const diag = await diagnoser.diagnoseChangeSet(description);
@@ -416456,7 +416636,7 @@ async function waitForChangeSet(cfn, ioHelper, stackNameOrArn, changeSetNameOrAr
416456
416636
  async function waitForChangeSetGone(cfn, ioHelper, stackNameOrArn, changeSetNameOrArn) {
416457
416637
  const stackDisplayName = stackNameFromArn(stackNameOrArn);
416458
416638
  const changeSetDisplayName = changeSetNameFromArn(changeSetNameOrArn);
416459
- await ioHelper.defaults.debug((0, import_util30.format)("Waiting for changeset %s on stack %s to finish deleting...", changeSetDisplayName, stackDisplayName));
416639
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Waiting for changeset %s on stack %s to finish deleting...", changeSetDisplayName, stackDisplayName));
416460
416640
  await waitFor(async () => {
416461
416641
  try {
416462
416642
  const description = await cfn.describeChangeSet({
@@ -416480,7 +416660,7 @@ async function createDiffChangeSet(ioHelper, options) {
416480
416660
  const env2 = await options.deployments.envs.accessStackForMutableStackOperations(options.stack);
416481
416661
  return await uploadBodyParameterAndCreateChangeSet(ioHelper, env2, {
416482
416662
  ...options,
416483
- includeNestedStacks: templateContainsNestedStacks(options.stack.template)
416663
+ includeNestedStacks: true
416484
416664
  });
416485
416665
  } catch (e32) {
416486
416666
  if (options.failOnError) {
@@ -416518,7 +416698,7 @@ async function uploadBodyParameterAndCreateChangeSet(ioHelper, env2, options) {
416518
416698
  );
416519
416699
  const cfn = env2.sdk.cloudFormation();
416520
416700
  const stack = await CloudFormationStack.lookup(cfn, options.stack.stackName, false);
416521
- const exists = stack.exists && stack.stackStatus.name !== "REVIEW_IN_PROGRESS";
416701
+ const exists = stack.exists && stack.stackStatus.name !== "REVIEW_IN_PROGRESS" && stack.stackStatus.name !== "DELETE_IN_PROGRESS";
416522
416702
  const executionRoleArn = await env2.replacePlaceholders(options.stack.cloudFormationExecutionRoleArn);
416523
416703
  await ioHelper.defaults.info(
416524
416704
  "Hold on while we create a read-only change set to get a diff with accurate replacement information (use --method=template to use a less accurate but faster template-only diff)\n"
@@ -416584,7 +416764,7 @@ async function createChangeSetAndCleanup(ioHelper, options) {
416584
416764
  Tags: toCfnTags(options.stack.tags),
416585
416765
  Capabilities: ["CAPABILITY_IAM", "CAPABILITY_NAMED_IAM", "CAPABILITY_AUTO_EXPAND"]
416586
416766
  });
416587
- await ioHelper.defaults.debug((0, import_util30.format)("Initiated creation of changeset: %s; waiting for it to finish creating...", changeSet.Id));
416767
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Initiated creation of changeset: %s; waiting for it to finish creating...", changeSet.Id));
416588
416768
  const createdChangeSet = await waitForChangeSet(
416589
416769
  options.cfn,
416590
416770
  ioHelper,
@@ -416601,6 +416781,13 @@ async function createChangeSetAndCleanup(ioHelper, options) {
416601
416781
  changeSet.Id ?? options.changeSetName,
416602
416782
  changeSet.StackId ?? options.stack.stackName
416603
416783
  );
416784
+ if (!options.exists) {
416785
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Deleting empty stack created by diff changeset: %s", changeSet.StackId ?? options.stack.stackName));
416786
+ await options.cfn.deleteStack({
416787
+ StackName: changeSet.StackId ?? options.stack.stackName,
416788
+ ClientRequestToken: (0, import_node_crypto11.randomUUID)()
416789
+ });
416790
+ }
416604
416791
  return createdChangeSet;
416605
416792
  }
416606
416793
  function toCfnTags(tags) {
@@ -416652,28 +416839,29 @@ async function waitForStackDeploy(cfn, ioHelper, stackName) {
416652
416839
  }
416653
416840
  async function stabilizeStack(cfn, ioHelper, stackNameOrArn) {
416654
416841
  const stackDisplayName = stackNameFromArn(stackNameOrArn);
416655
- await ioHelper.defaults.debug((0, import_util30.format)("Waiting for stack %s to finish creating or updating...", stackDisplayName));
416842
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Waiting for stack %s to finish creating or updating...", stackDisplayName));
416656
416843
  return waitFor(async () => {
416657
416844
  const stack = await CloudFormationStack.lookup(cfn, stackNameOrArn);
416658
416845
  if (!stack.exists) {
416659
- await ioHelper.defaults.debug((0, import_util30.format)("Stack %s does not exist", stackDisplayName));
416846
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Stack %s does not exist", stackDisplayName));
416660
416847
  return null;
416661
416848
  }
416662
416849
  const status = stack.stackStatus;
416663
416850
  if (status.isInProgress) {
416664
- await ioHelper.defaults.debug((0, import_util30.format)("Stack %s has an ongoing operation in progress and is not stable (%s)", stackDisplayName, status));
416851
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Stack %s has an ongoing operation in progress and is not stable (%s)", stackDisplayName, status));
416665
416852
  return void 0;
416666
416853
  } else if (status.isReviewInProgress) {
416667
- await ioHelper.defaults.debug((0, import_util30.format)("Stack %s is in REVIEW_IN_PROGRESS state. Considering this is a stable status (%s)", stackDisplayName, status));
416854
+ await ioHelper.defaults.debug((0, import_node_util2.format)("Stack %s is in REVIEW_IN_PROGRESS state. Considering this is a stable status (%s)", stackDisplayName, status));
416668
416855
  }
416669
416856
  return stack;
416670
416857
  });
416671
416858
  }
416672
- var import_util30, import_cdk_assets_lib2, cxapi2, import_cloud_assembly_api6, import_client_cloudformation4, TemplateParameters, ParameterValues;
416859
+ var import_node_crypto11, import_node_util2, import_cdk_assets_lib2, cxapi2, import_cloud_assembly_api6, import_client_cloudformation4, TemplateParameters, ParameterValues;
416673
416860
  var init_cfn_api = __esm({
416674
416861
  "../toolkit-lib/lib/api/deployments/cfn-api.ts"() {
416675
416862
  "use strict";
416676
- import_util30 = require("util");
416863
+ import_node_crypto11 = require("node:crypto");
416864
+ import_node_util2 = require("node:util");
416677
416865
  import_cdk_assets_lib2 = __toESM(require_lib6());
416678
416866
  cxapi2 = __toESM(require_lib3());
416679
416867
  import_cloud_assembly_api6 = __toESM(require_lib3());
@@ -416794,11 +416982,11 @@ var init_cfn_api = __esm({
416794
416982
  });
416795
416983
 
416796
416984
  // ../toolkit-lib/lib/api/toolkit-info.ts
416797
- var import_util31, chalk5, DEFAULT_TOOLKIT_STACK_NAME, ToolkitInfo, ExistingToolkitInfo, BootstrapStackNotFoundInfo;
416985
+ var import_util30, chalk5, DEFAULT_TOOLKIT_STACK_NAME, ToolkitInfo, ExistingToolkitInfo, BootstrapStackNotFoundInfo;
416798
416986
  var init_toolkit_info = __esm({
416799
416987
  "../toolkit-lib/lib/api/toolkit-info.ts"() {
416800
416988
  "use strict";
416801
- import_util31 = require("util");
416989
+ import_util30 = require("util");
416802
416990
  chalk5 = __toESM(require_source());
416803
416991
  init_bootstrap_props();
416804
416992
  init_toolkit_error();
@@ -416818,7 +417006,7 @@ var init_toolkit_info = __esm({
416818
417006
  const stack = await stabilizeStack(cfn, ioHelper, stackName);
416819
417007
  if (!stack) {
416820
417008
  await ioHelper.defaults.debug(
416821
- (0, import_util31.format)(
417009
+ (0, import_util30.format)(
416822
417010
  "The environment %s doesn't have the CDK toolkit stack (%s) installed. Use %s to setup your environment for use with the toolkit.",
416823
417011
  environment.name,
416824
417012
  stackName,
@@ -416829,7 +417017,7 @@ var init_toolkit_info = __esm({
416829
417017
  }
416830
417018
  if (stack.stackStatus.isCreationFailure) {
416831
417019
  await ioHelper.defaults.debug(
416832
- (0, import_util31.format)(
417020
+ (0, import_util30.format)(
416833
417021
  "The environment %s has a CDK toolkit stack (%s) that failed to create. Use %s to try provisioning it again.",
416834
417022
  environment.name,
416835
417023
  stackName,
@@ -421139,14 +421327,14 @@ function settingsFromSynthOptions(synthOpts = {}) {
421139
421327
  function parametersFromSynthOptions(synthOptions) {
421140
421328
  return synthParametersFromSettings(settingsFromSynthOptions(synthOptions ?? {}));
421141
421329
  }
421142
- var import_dispose_polyfill4, os9, path26, import_node_util2, import_cloud_assembly_api9, cxschema9, cxapi4, fs28, import_semver, ExecutionEnvironment;
421330
+ var import_dispose_polyfill4, os9, path26, import_node_util3, import_cloud_assembly_api9, cxschema9, cxapi4, fs28, import_semver, ExecutionEnvironment;
421143
421331
  var init_prepare_source = __esm({
421144
421332
  "../toolkit-lib/lib/api/cloud-assembly/private/prepare-source.ts"() {
421145
421333
  "use strict";
421146
421334
  import_dispose_polyfill4 = __toESM(require_dispose_polyfill());
421147
421335
  os9 = __toESM(require("node:os"));
421148
421336
  path26 = __toESM(require("node:path"));
421149
- import_node_util2 = require("node:util");
421337
+ import_node_util3 = require("node:util");
421150
421338
  import_cloud_assembly_api9 = __toESM(require_lib3());
421151
421339
  cxschema9 = __toESM(require_lib2());
421152
421340
  cxapi4 = __toESM(require_lib8());
@@ -421284,10 +421472,10 @@ var init_prepare_source = __esm({
421284
421472
  const debugFn = /* @__PURE__ */ __name((msg) => this.ioHelper.notify(IO.CDK_ASSEMBLY_I0010.msg(msg)), "debugFn");
421285
421473
  const env2 = this.options.resolveDefaultAppEnv ? await prepareDefaultEnvironment(this.sdkProvider, debugFn) : {};
421286
421474
  env2[cxapi4.OUTDIR_ENV] = this.outdir;
421287
- await debugFn((0, import_node_util2.format)("outdir:", this.outdir));
421475
+ await debugFn((0, import_node_util3.format)("outdir:", this.outdir));
421288
421476
  env2[cxapi4.CLI_ASM_VERSION_ENV] = cxschema9.Manifest.version();
421289
421477
  env2[cxapi4.CLI_VERSION_ENV] = versionNumber();
421290
- await debugFn((0, import_node_util2.format)("env:", env2));
421478
+ await debugFn((0, import_node_util3.format)("env:", env2));
421291
421479
  return env2;
421292
421480
  }
421293
421481
  /**
@@ -421352,12 +421540,12 @@ var init_readable_assembly = __esm({
421352
421540
  });
421353
421541
 
421354
421542
  // ../toolkit-lib/lib/api/cloud-assembly/source-builder.ts
421355
- var path27, import_util36, cxapi5, fs30, CloudAssemblySourceBuilder;
421543
+ var path27, import_util35, cxapi5, fs30, CloudAssemblySourceBuilder;
421356
421544
  var init_source_builder = __esm({
421357
421545
  "../toolkit-lib/lib/api/cloud-assembly/source-builder.ts"() {
421358
421546
  "use strict";
421359
421547
  path27 = __toESM(require("path"));
421360
- import_util36 = require("util");
421548
+ import_util35 = require("util");
421361
421549
  cxapi5 = __toESM(require_lib3());
421362
421550
  fs30 = __toESM(require_lib4());
421363
421551
  init_context_store();
@@ -421423,7 +421611,7 @@ var init_source_builder = __esm({
421423
421611
  ...await contextStore.read(),
421424
421612
  ...synthParams.context
421425
421613
  };
421426
- await services.ioHelper.defaults.debug((0, import_util36.format)("context:", fullContext));
421614
+ await services.ioHelper.defaults.debug((0, import_util35.format)("context:", fullContext));
421427
421615
  const env2 = noUndefined({
421428
421616
  // Versioning, outdir, default account and region
421429
421617
  ...await execution.defaultEnvVars(),
@@ -421562,7 +421750,7 @@ var init_source_builder = __esm({
421562
421750
  ...await contextStore.read(),
421563
421751
  ...synthParams.context
421564
421752
  };
421565
- await services.ioHelper.defaults.debug((0, import_util36.format)("context:", fullContext));
421753
+ await services.ioHelper.defaults.debug((0, import_util35.format)("context:", fullContext));
421566
421754
  const env2 = noUndefined({
421567
421755
  // Need to start with full env of `writeContextToEnv` will not be able to do the size
421568
421756
  // calculation correctly.
@@ -432416,11 +432604,11 @@ function _diffStrings(oldStr, newStr, context) {
432416
432604
  }
432417
432605
  __name(_findIndent, "_findIndent");
432418
432606
  }
432419
- var import_util47, chalk11, PATH_METADATA_KEY3, structuredPatch, ADDITION2, CONTEXT, UPDATE2, REMOVAL2, IMPORT, Formatter;
432607
+ var import_util46, chalk11, PATH_METADATA_KEY3, structuredPatch, ADDITION2, CONTEXT, UPDATE2, REMOVAL2, IMPORT, Formatter;
432420
432608
  var init_format = __esm({
432421
432609
  "../cloudformation-diff/lib/format.ts"() {
432422
432610
  "use strict";
432423
- import_util47 = require("util");
432611
+ import_util46 = require("util");
432424
432612
  chalk11 = __toESM(require_source());
432425
432613
  init_util6();
432426
432614
  init_diff_template();
@@ -432449,10 +432637,10 @@ var init_format = __esm({
432449
432637
  __name(this, "Formatter");
432450
432638
  }
432451
432639
  print(fmt, ...args) {
432452
- this.stream.write(chalk11.reset((0, import_util47.format)(fmt, ...args)) + "\n");
432640
+ this.stream.write(chalk11.reset((0, import_util46.format)(fmt, ...args)) + "\n");
432453
432641
  }
432454
432642
  warning(fmt, ...args) {
432455
- this.stream.write(chalk11.yellow((0, import_util47.format)(fmt, ...args)) + "\n");
432643
+ this.stream.write(chalk11.yellow((0, import_util46.format)(fmt, ...args)) + "\n");
432456
432644
  }
432457
432645
  formatSection(title, entryType, collection, formatter = this.formatDifference.bind(this)) {
432458
432646
  if (collection.differenceCount === 0) {
@@ -434887,7 +435075,7 @@ async function applyHotswapOperation(sdk, ioSpan, hotswapOperation) {
434887
435075
  sdk.appendCustomUserAgent(customUserAgent);
434888
435076
  const resourceText = /* @__PURE__ */ __name((r32) => r32.description ?? `${r32.resourceType} '${r32.physicalName ?? r32.logicalId}'`, "resourceText");
434889
435077
  await ioSpan.notify(IO.CDK_TOOLKIT_I5402.msg(
434890
- hotswapOperation.change.resources.map((r32) => (0, import_util53.format)(` ${ICON} %s`, chalk14.bold(resourceText(r32)))).join("\n"),
435078
+ hotswapOperation.change.resources.map((r32) => (0, import_util52.format)(` ${ICON} %s`, chalk14.bold(resourceText(r32)))).join("\n"),
434891
435079
  hotswapOperation.change
434892
435080
  ));
434893
435081
  try {
@@ -434902,7 +435090,7 @@ async function applyHotswapOperation(sdk, ioSpan, hotswapOperation) {
434902
435090
  throw e32;
434903
435091
  }
434904
435092
  await ioSpan.notify(IO.CDK_TOOLKIT_I5403.msg(
434905
- hotswapOperation.change.resources.map((r32) => (0, import_util53.format)(` ${ICON} %s %s`, chalk14.bold(resourceText(r32)), chalk14.green("hotswapped!"))).join("\n"),
435093
+ hotswapOperation.change.resources.map((r32) => (0, import_util52.format)(` ${ICON} %s %s`, chalk14.bold(resourceText(r32)), chalk14.green("hotswapped!"))).join("\n"),
434906
435094
  hotswapOperation.change
434907
435095
  ));
434908
435096
  sdk.removeCustomUserAgent(customUserAgent);
@@ -434931,9 +435119,9 @@ async function logRejectedChanges(ioSpan, rejectedChanges, hotswapMode) {
434931
435119
  }
434932
435120
  const messages = [""];
434933
435121
  if (hotswapMode === "hotswap-only") {
434934
- messages.push((0, import_util53.format)("%s %s", chalk14.red("\u26A0\uFE0F"), chalk14.red("The following non-hotswappable changes were found. To reconcile these using CloudFormation, specify --hotswap-fallback")));
435122
+ messages.push((0, import_util52.format)("%s %s", chalk14.red("\u26A0\uFE0F"), chalk14.red("The following non-hotswappable changes were found. To reconcile these using CloudFormation, specify --hotswap-fallback")));
434935
435123
  } else {
434936
- messages.push((0, import_util53.format)("%s %s", chalk14.red("\u26A0\uFE0F"), chalk14.red("The following non-hotswappable changes were found:")));
435124
+ messages.push((0, import_util52.format)("%s %s", chalk14.red("\u26A0\uFE0F"), chalk14.red("The following non-hotswappable changes were found:")));
434937
435125
  }
434938
435126
  for (const { change } of rejectedChanges) {
434939
435127
  messages.push(" " + nonHotswappableChangeMessage(change));
@@ -434946,7 +435134,7 @@ function nonHotswappableChangeMessage(change) {
434946
435134
  const reason = change.description ?? change.reason;
434947
435135
  switch (subject.type) {
434948
435136
  case "Output":
434949
- return (0, import_util53.format)(
435137
+ return (0, import_util52.format)(
434950
435138
  "output: %s, reason: %s",
434951
435139
  chalk14.bold(subject.logicalId),
434952
435140
  chalk14.red(reason)
@@ -434957,7 +435145,7 @@ function nonHotswappableChangeMessage(change) {
434957
435145
  }
434958
435146
  function nonHotswappableResourceMessage(subject, reason) {
434959
435147
  if (subject.rejectedProperties?.length) {
434960
- return (0, import_util53.format)(
435148
+ return (0, import_util52.format)(
434961
435149
  "resource: %s, type: %s, rejected changes: %s, reason: %s",
434962
435150
  chalk14.bold(subject.logicalId),
434963
435151
  chalk14.bold(subject.resourceType),
@@ -434965,18 +435153,18 @@ function nonHotswappableResourceMessage(subject, reason) {
434965
435153
  chalk14.red(reason)
434966
435154
  );
434967
435155
  }
434968
- return (0, import_util53.format)(
435156
+ return (0, import_util52.format)(
434969
435157
  "resource: %s, type: %s, reason: %s",
434970
435158
  chalk14.bold(subject.logicalId),
434971
435159
  chalk14.bold(subject.resourceType),
434972
435160
  chalk14.red(reason)
434973
435161
  );
434974
435162
  }
434975
- var import_util53, cfn_diff, chalk14, pLimit2, RESOURCE_DETECTORS;
435163
+ var import_util52, cfn_diff, chalk14, pLimit2, RESOURCE_DETECTORS;
434976
435164
  var init_hotswap_deployments = __esm({
434977
435165
  "../toolkit-lib/lib/api/hotswap/hotswap-deployments.ts"() {
434978
435166
  "use strict";
434979
- import_util53 = require("util");
435167
+ import_util52 = require("util");
434980
435168
  cfn_diff = __toESM(require_lib11());
434981
435169
  chalk14 = __toESM(require_source());
434982
435170
  init_payloads();
@@ -435082,7 +435270,7 @@ async function deployStack(options, ioHelper) {
435082
435270
  await ioHelper.defaults.debug(
435083
435271
  `Found existing stack ${deployName} that had previously failed creation. Deleting it before attempting to re-create it.`
435084
435272
  );
435085
- await cfn.deleteStack({ StackName: cloudFormationStack.stackId, ClientRequestToken: (0, import_node_crypto11.randomUUID)() });
435273
+ await cfn.deleteStack({ StackName: cloudFormationStack.stackId, ClientRequestToken: (0, import_node_crypto12.randomUUID)() });
435086
435274
  const deletedStack = await waitForStackDelete(cfn, ioHelper, cloudFormationStack.stackId);
435087
435275
  if (deletedStack && deletedStack.stackStatus.name !== "DELETE_COMPLETE") {
435088
435276
  throw new DeploymentError(
@@ -435107,7 +435295,7 @@ async function deployStack(options, ioHelper) {
435107
435295
  await ioHelper.defaults.debug(`${deployName}: skipping deployment (use --force to override)`);
435108
435296
  if (deploymentMethod?.method === "hotswap") {
435109
435297
  await ioHelper.defaults.info(
435110
- (0, import_node_util3.format)(
435298
+ (0, import_node_util4.format)(
435111
435299
  `
435112
435300
  ${ICON} %s
435113
435301
  `,
@@ -435161,7 +435349,7 @@ async function deployStack(options, ioHelper) {
435161
435349
  );
435162
435350
  return hotswapDeploymentResult;
435163
435351
  }
435164
- await ioHelper.defaults.info((0, import_node_util3.format)(
435352
+ await ioHelper.defaults.info((0, import_node_util4.format)(
435165
435353
  "Could not perform a hotswap deployment, as the stack %s contains non-Asset changes",
435166
435354
  stackArtifact.displayName
435167
435355
  ));
@@ -435169,7 +435357,7 @@ async function deployStack(options, ioHelper) {
435169
435357
  if (!(e32 instanceof CfnEvaluationException)) {
435170
435358
  throw e32;
435171
435359
  }
435172
- await ioHelper.defaults.info((0, import_node_util3.format)(
435360
+ await ioHelper.defaults.info((0, import_node_util4.format)(
435173
435361
  "Could not perform a hotswap deployment, because the CloudFormation template could not be resolved: %s",
435174
435362
  formatErrorMessage(e32)
435175
435363
  ));
@@ -435214,7 +435402,7 @@ async function destroyStack(options, ioHelper) {
435214
435402
  });
435215
435403
  await monitor.start();
435216
435404
  try {
435217
- await cfn.deleteStack({ StackName: currentStack.stackId, RoleARN: options.roleArn, ClientRequestToken: (0, import_node_crypto11.randomUUID)() });
435405
+ await cfn.deleteStack({ StackName: currentStack.stackId, RoleARN: options.roleArn, ClientRequestToken: (0, import_node_crypto12.randomUUID)() });
435218
435406
  const destroyedStack = await waitForStackDelete(cfn, ioHelper, currentStack.stackId);
435219
435407
  if (destroyedStack && destroyedStack.stackStatus.name !== "DELETE_COMPLETE") {
435220
435408
  throw new DeploymentError(`Failed to destroy ${deployName}: ${destroyedStack.stackStatus}`, "StackDestroyFailed");
@@ -435305,12 +435493,12 @@ function hasReplacement(cs) {
435305
435493
  return a32 === "ReplaceAndDelete" || a32 === "ReplaceAndRetain" || a32 === "ReplaceAndSnapshot";
435306
435494
  });
435307
435495
  }
435308
- var import_node_crypto11, import_node_util3, chalk15, FullCloudFormationDeployment;
435496
+ var import_node_crypto12, import_node_util4, chalk15, FullCloudFormationDeployment;
435309
435497
  var init_deploy_stack = __esm({
435310
435498
  "../toolkit-lib/lib/api/deployments/deploy-stack.ts"() {
435311
435499
  "use strict";
435312
- import_node_crypto11 = require("node:crypto");
435313
- import_node_util3 = require("node:util");
435500
+ import_node_crypto12 = require("node:crypto");
435501
+ import_node_util4 = require("node:util");
435314
435502
  chalk15 = __toESM(require_source());
435315
435503
  init_asset_manifest_builder();
435316
435504
  init_asset_publishing();
@@ -435344,7 +435532,7 @@ var init_deploy_stack = __esm({
435344
435532
  this.stackName = options.deployName ?? stackArtifact.stackName;
435345
435533
  this.update = cloudFormationStack.exists && cloudFormationStack.stackStatus.name !== "REVIEW_IN_PROGRESS";
435346
435534
  this.verb = this.update ? "update" : "create";
435347
- this.uuid = (0, import_node_crypto11.randomUUID)();
435535
+ this.uuid = (0, import_node_crypto12.randomUUID)();
435348
435536
  }
435349
435537
  deploymentMethod;
435350
435538
  options;
@@ -435385,9 +435573,9 @@ var init_deploy_stack = __esm({
435385
435573
  const changeSetDescription = await this.createChangeSet(changeSetName, execute, importExistingResources, revertDrift);
435386
435574
  await this.updateTerminationProtection();
435387
435575
  if (changeSetHasNoChanges(changeSetDescription)) {
435388
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("No changes are to be performed on %s.", this.stackName));
435576
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("No changes are to be performed on %s.", this.stackName));
435389
435577
  if (execute) {
435390
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("Deleting empty change set %s", changeSetDescription.ChangeSetId));
435578
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("Deleting empty change set %s", changeSetDescription.ChangeSetId));
435391
435579
  await this.cfn.deleteChangeSet({
435392
435580
  StackName: changeSetDescription.StackId ?? this.stackName,
435393
435581
  ChangeSetName: changeSetDescription.ChangeSetId ?? changeSetName
@@ -435412,7 +435600,7 @@ var init_deploy_stack = __esm({
435412
435600
  };
435413
435601
  }
435414
435602
  if (!execute) {
435415
- await this.ioHelper.defaults.info((0, import_node_util3.format)(
435603
+ await this.ioHelper.defaults.info((0, import_node_util4.format)(
435416
435604
  "Changeset %s created and waiting in review for manual execution (--no-execute)",
435417
435605
  changeSetDescription.ChangeSetId
435418
435606
  ));
@@ -435463,7 +435651,7 @@ var init_deploy_stack = __esm({
435463
435651
  async createChangeSet(changeSetName, willExecute, importExistingResources, revertDrift) {
435464
435652
  await this.cleanupOldChangeset(changeSetName);
435465
435653
  await this.ioHelper.defaults.debug(`Attempting to create ChangeSet with name ${changeSetName} to ${this.verb} stack ${this.stackName}`);
435466
- await this.ioHelper.defaults.info((0, import_node_util3.format)("%s: creating CloudFormation changeset...", chalk15.bold(this.stackName)));
435654
+ await this.ioHelper.defaults.info((0, import_node_util4.format)("%s: creating CloudFormation changeset...", chalk15.bold(this.stackName)));
435467
435655
  const changeSet = await this.cfn.createChangeSet({
435468
435656
  StackName: this.stackName,
435469
435657
  ChangeSetName: changeSetName,
@@ -435473,20 +435661,17 @@ var init_deploy_stack = __esm({
435473
435661
  ClientToken: `create${this.uuid}`,
435474
435662
  ImportExistingResources: importExistingResources,
435475
435663
  DeploymentMode: revertDrift ? "REVERT_DRIFT" : void 0,
435476
- // This is necessary to trigger early validation on nested stacks as well
435477
- // TODO: We currently have a test explicitly checking that this is NOT set to true, but on the other
435478
- // hand for 'cdk diff' we DO turn it on. Investigate later.
435479
- // IncludeNestedStacks: true,
435664
+ IncludeNestedStacks: this.options.resourcesToImport || revertDrift ? void 0 : true,
435480
435665
  ...this.commonPrepareOptions()
435481
435666
  });
435482
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("Initiated creation of changeset: %s; waiting for it to finish creating...", changeSet.Id));
435667
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("Initiated creation of changeset: %s; waiting for it to finish creating...", changeSet.Id));
435483
435668
  return waitForChangeSet(this.cfn, this.ioHelper, changeSet.StackId ?? this.stackName, changeSet.Id ?? changeSetName, {
435484
435669
  fetchAll: willExecute,
435485
435670
  diagnoser: this.diagnoser
435486
435671
  });
435487
435672
  }
435488
435673
  async executeChangeSet(changeSet) {
435489
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("Initiating execution of changeset %s on stack %s", changeSet.ChangeSetId, this.stackName));
435674
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("Initiating execution of changeset %s on stack %s", changeSet.ChangeSetId, this.stackName));
435490
435675
  await this.cfn.executeChangeSet({
435491
435676
  StackName: changeSet.StackId ?? this.stackName,
435492
435677
  ChangeSetName: changeSet.ChangeSetId,
@@ -435494,7 +435679,7 @@ var init_deploy_stack = __esm({
435494
435679
  ...this.commonExecuteOptions()
435495
435680
  });
435496
435681
  await this.ioHelper.defaults.debug(
435497
- (0, import_node_util3.format)(
435682
+ (0, import_node_util4.format)(
435498
435683
  "Execution of changeset %s on stack %s has started; waiting for the update to complete...",
435499
435684
  changeSet.ChangeSetId,
435500
435685
  this.stackName
@@ -435518,7 +435703,7 @@ var init_deploy_stack = __esm({
435518
435703
  const terminationProtection = this.stackArtifact.terminationProtection ?? false;
435519
435704
  if (!!this.cloudFormationStack.terminationProtection !== terminationProtection) {
435520
435705
  await this.ioHelper.defaults.debug(
435521
- (0, import_node_util3.format)(
435706
+ (0, import_node_util4.format)(
435522
435707
  "Updating termination protection from %s to %s for stack %s",
435523
435708
  this.cloudFormationStack.terminationProtection,
435524
435709
  terminationProtection,
@@ -435529,11 +435714,11 @@ var init_deploy_stack = __esm({
435529
435714
  StackName: this.stackName,
435530
435715
  EnableTerminationProtection: terminationProtection
435531
435716
  });
435532
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("Termination protection updated to %s for stack %s", terminationProtection, this.stackName));
435717
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("Termination protection updated to %s for stack %s", terminationProtection, this.stackName));
435533
435718
  }
435534
435719
  }
435535
435720
  async directDeployment() {
435536
- await this.ioHelper.defaults.info((0, import_node_util3.format)("%s: %s stack...", chalk15.bold(this.stackName), this.update ? "updating" : "creating"));
435721
+ await this.ioHelper.defaults.info((0, import_node_util4.format)("%s: %s stack...", chalk15.bold(this.stackName), this.update ? "updating" : "creating"));
435537
435722
  const startTime = /* @__PURE__ */ new Date();
435538
435723
  if (this.update) {
435539
435724
  await this.updateTerminationProtection();
@@ -435547,7 +435732,7 @@ var init_deploy_stack = __esm({
435547
435732
  return await this.monitorDeployment(startTime, stack.StackId, void 0);
435548
435733
  } catch (err) {
435549
435734
  if (err.message === "No updates are to be performed.") {
435550
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("No updates are to be performed for stack %s", this.stackName));
435735
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("No updates are to be performed for stack %s", this.stackName));
435551
435736
  return {
435552
435737
  type: "did-deploy-stack",
435553
435738
  noOp: true,
@@ -435598,7 +435783,7 @@ var init_deploy_stack = __esm({
435598
435783
  } finally {
435599
435784
  await monitor.stop();
435600
435785
  }
435601
- await this.ioHelper.defaults.debug((0, import_node_util3.format)("Stack %s has completed updating", this.stackName));
435786
+ await this.ioHelper.defaults.debug((0, import_node_util4.format)("Stack %s has completed updating", this.stackName));
435602
435787
  return {
435603
435788
  type: "did-deploy-stack",
435604
435789
  noOp: false,
@@ -435647,11 +435832,11 @@ var init_deploy_stack = __esm({
435647
435832
  function suffixWithErrors2(msg, errors) {
435648
435833
  return errors && errors.length > 0 ? `${msg}: ${errors.join(", ")}` : msg;
435649
435834
  }
435650
- var import_node_crypto12, cdk_assets, chalk16, BOOTSTRAP_STACK_VERSION_FOR_ROLLBACK, Deployments, ParallelSafeAssetProgress;
435835
+ var import_node_crypto13, cdk_assets, chalk16, BOOTSTRAP_STACK_VERSION_FOR_ROLLBACK, Deployments, ParallelSafeAssetProgress;
435651
435836
  var init_deployments = __esm({
435652
435837
  "../toolkit-lib/lib/api/deployments/deployments.ts"() {
435653
435838
  "use strict";
435654
- import_node_crypto12 = require("node:crypto");
435839
+ import_node_crypto13 = require("node:crypto");
435655
435840
  cdk_assets = __toESM(require_lib6());
435656
435841
  chalk16 = __toESM(require_source());
435657
435842
  init_asset_manifest_builder();
@@ -435822,7 +436007,7 @@ var init_deployments = __esm({
435822
436007
  }
435823
436008
  await cfn.deleteChangeSet({ StackName: deployName, ChangeSetName: changeSetName });
435824
436009
  if (cloudFormationStack.stackStatus.name === "REVIEW_IN_PROGRESS") {
435825
- await cfn.deleteStack({ StackName: deployName, ClientRequestToken: (0, import_node_crypto12.randomUUID)() });
436010
+ await cfn.deleteStack({ StackName: deployName, ClientRequestToken: (0, import_node_crypto13.randomUUID)() });
435826
436011
  await waitForStackDelete(cfn, this.ioHelper, deployName);
435827
436012
  }
435828
436013
  }
@@ -435878,7 +436063,7 @@ var init_deployments = __esm({
435878
436063
  await cfn.rollbackStack({
435879
436064
  StackName: stackArn,
435880
436065
  RoleARN: executionRoleArn,
435881
- ClientRequestToken: (0, import_node_crypto12.randomUUID)(),
436066
+ ClientRequestToken: (0, import_node_crypto13.randomUUID)(),
435882
436067
  // Enabling this is just the better overall default, the only reason it isn't the upstream default is backwards compatibility
435883
436068
  RetainExceptOnCreate: true
435884
436069
  });
@@ -435896,7 +436081,7 @@ var init_deployments = __esm({
435896
436081
  await this.ioHelper.defaults.warn(`Continuing rollback of stack ${deployName}${skipDescription}`);
435897
436082
  await cfn.continueUpdateRollback({
435898
436083
  StackName: stackArn,
435899
- ClientRequestToken: (0, import_node_crypto12.randomUUID)(),
436084
+ ClientRequestToken: (0, import_node_crypto13.randomUUID)(),
435900
436085
  RoleARN: executionRoleArn,
435901
436086
  ResourcesToSkip: resourcesToSkip
435902
436087
  });
@@ -436175,11 +436360,11 @@ function obscureDiff(diff) {
436175
436360
  });
436176
436361
  }
436177
436362
  }
436178
- var import_node_util4, import_cloudformation_diff, chalk17, DiffFormatter;
436363
+ var import_node_util5, import_cloudformation_diff, chalk17, DiffFormatter;
436179
436364
  var init_diff_formatter = __esm({
436180
436365
  "../toolkit-lib/lib/api/diff/diff-formatter.ts"() {
436181
436366
  "use strict";
436182
- import_node_util4 = require("node:util");
436367
+ import_node_util5 = require("node:util");
436183
436368
  import_cloudformation_diff = __toESM(require_lib11());
436184
436369
  chalk17 = __toESM(require_source());
436185
436370
  init_payloads();
@@ -436263,7 +436448,7 @@ var init_diff_formatter = __esm({
436263
436448
  let filteredChangesCount = 0;
436264
436449
  try {
436265
436450
  if (stackName && (!options.quiet || !diff.isEmpty)) {
436266
- stream.write((0, import_node_util4.format)(`Stack ${chalk17.bold(stackName)}
436451
+ stream.write((0, import_node_util5.format)(`Stack ${chalk17.bold(stackName)}
436267
436452
  `));
436268
436453
  }
436269
436454
  if (!options.quiet && this.isImport) {
@@ -436338,7 +436523,7 @@ var init_diff_formatter = __esm({
436338
436523
  const permissionChangeType = permissionTypeFromDiff(diff);
436339
436524
  const stream = new StringWriteStream();
436340
436525
  if (!options.quiet || permissionChangeType !== "none" /* NONE */) {
436341
- stream.write((0, import_node_util4.format)(`Stack ${chalk17.bold(stackName)}
436526
+ stream.write((0, import_node_util5.format)(`Stack ${chalk17.bold(stackName)}
436342
436527
  `));
436343
436528
  }
436344
436529
  try {
@@ -436407,11 +436592,11 @@ function removeNonImportResources(stack) {
436407
436592
  delete template.Outputs;
436408
436593
  return template;
436409
436594
  }
436410
- var import_util57, cfnDiff, chalk18, fs32, ResourceImporter;
436595
+ var import_util56, cfnDiff, chalk18, fs32, ResourceImporter;
436411
436596
  var init_importer = __esm({
436412
436597
  "../toolkit-lib/lib/api/resource-import/importer.ts"() {
436413
436598
  "use strict";
436414
- import_util57 = require("util");
436599
+ import_util56 = require("util");
436415
436600
  cfnDiff = __toESM(require_lib11());
436416
436601
  chalk18 = __toESM(require_source());
436417
436602
  fs32 = __toESM(require_lib4());
@@ -436475,12 +436660,12 @@ var init_importer = __esm({
436475
436660
  const descr = this.describeResource(resource.logicalId);
436476
436661
  const idProps = remaining[resource.logicalId];
436477
436662
  if (idProps) {
436478
- await this.ioHelper.defaults.info((0, import_util57.format)("%s: importing using %s", chalk18.blue(descr), chalk18.blue(fmtdict(idProps))));
436663
+ await this.ioHelper.defaults.info((0, import_util56.format)("%s: importing using %s", chalk18.blue(descr), chalk18.blue(fmtdict(idProps))));
436479
436664
  ret.importResources.push(resource);
436480
436665
  ret.resourceMap[resource.logicalId] = idProps;
436481
436666
  delete remaining[resource.logicalId];
436482
436667
  } else {
436483
- await this.ioHelper.defaults.info((0, import_util57.format)("%s: skipping", chalk18.blue(descr)));
436668
+ await this.ioHelper.defaults.info((0, import_util56.format)("%s: skipping", chalk18.blue(descr)));
436484
436669
  }
436485
436670
  }
436486
436671
  const unknown = Object.keys(remaining);
@@ -436524,9 +436709,9 @@ var init_importer = __esm({
436524
436709
  });
436525
436710
  assertIsSuccessfulDeployStackResult(result2);
436526
436711
  const message2 = result2.noOp ? " \u2705 %s (no changes)" : " \u2705 %s";
436527
- await this.ioHelper.defaults.info("\n" + chalk18.green((0, import_util57.format)(message2, this.stack.displayName)));
436712
+ await this.ioHelper.defaults.info("\n" + chalk18.green((0, import_util56.format)(message2, this.stack.displayName)));
436528
436713
  } catch (e32) {
436529
- await this.ioHelper.notify(IO.CDK_TOOLKIT_E3900.msg((0, import_util57.format)("\n \u274C %s failed: %s", chalk18.bold(this.stack.displayName), e32), { error: e32 }));
436714
+ await this.ioHelper.notify(IO.CDK_TOOLKIT_E3900.msg((0, import_util56.format)("\n \u274C %s failed: %s", chalk18.bold(this.stack.displayName), e32), { error: e32 }));
436530
436715
  throw e32;
436531
436716
  }
436532
436717
  }
@@ -436656,7 +436841,7 @@ var init_importer = __esm({
436656
436841
  for (const idProp of idProps) {
436657
436842
  const defaultValue = resourceProps[idProp] ?? "";
436658
436843
  const response = await this.ioHelper.requestResponse(IO.CDK_TOOLKIT_I3110.req(
436659
- (0, import_util57.format)(promptPattern, chalk18.blue(idProp)),
436844
+ (0, import_util56.format)(promptPattern, chalk18.blue(idProp)),
436660
436845
  {
436661
436846
  resource: {
436662
436847
  name: resourceName,
@@ -437587,7 +437772,7 @@ async function cfnDiff2(ioHelper, stacks, deployments, options, sdkProvider, inc
437587
437772
  parameters: methodOptions.parameters ?? {},
437588
437773
  failOnError: !(methodOptions.fallbackToTemplate ?? true),
437589
437774
  importExistingResources: methodOptions.importExistingResources,
437590
- uuid: (0, import_node_crypto13.randomUUID)(),
437775
+ uuid: (0, import_node_crypto14.randomUUID)(),
437591
437776
  willExecute: false
437592
437777
  }) : void 0;
437593
437778
  if (changeSet) {
@@ -437638,11 +437823,11 @@ function appendObject(obj1, obj2) {
437638
437823
  }
437639
437824
  return obj1;
437640
437825
  }
437641
- var import_node_crypto13, fs34;
437826
+ var import_node_crypto14, fs34;
437642
437827
  var init_helpers4 = __esm({
437643
437828
  "../toolkit-lib/lib/actions/diff/private/helpers.ts"() {
437644
437829
  "use strict";
437645
- import_node_crypto13 = require("node:crypto");
437830
+ import_node_crypto14 = require("node:crypto");
437646
437831
  fs34 = __toESM(require_lib4());
437647
437832
  init_diff();
437648
437833
  init_cfn_api();
@@ -438493,11 +438678,11 @@ var init_io = __esm({
438493
438678
  });
438494
438679
 
438495
438680
  // ../toolkit-lib/lib/api/logs-monitor/logs-monitor.ts
438496
- var import_node_crypto14, util7, chalk22, CloudWatchLogEventMonitor;
438681
+ var import_node_crypto15, util7, chalk22, CloudWatchLogEventMonitor;
438497
438682
  var init_logs_monitor2 = __esm({
438498
438683
  "../toolkit-lib/lib/api/logs-monitor/logs-monitor.ts"() {
438499
438684
  "use strict";
438500
- import_node_crypto14 = require("node:crypto");
438685
+ import_node_crypto15 = require("node:crypto");
438501
438686
  util7 = __toESM(require("node:util"));
438502
438687
  chalk22 = __toESM(require_source());
438503
438688
  init_util();
@@ -438533,7 +438718,7 @@ var init_logs_monitor2 = __esm({
438533
438718
  * resume reading/printing events
438534
438719
  */
438535
438720
  async activate() {
438536
- this.monitorId = (0, import_node_crypto14.randomUUID)();
438721
+ this.monitorId = (0, import_node_crypto15.randomUUID)();
438537
438722
  await this.ioHelper.notify(IO.CDK_TOOLKIT_I5032.msg("Start monitoring log groups", {
438538
438723
  monitor: this.monitorId,
438539
438724
  logGroupNames: this.logGroupNames()
@@ -439397,11 +439582,11 @@ var init_tags2 = __esm({
439397
439582
  });
439398
439583
 
439399
439584
  // ../toolkit-lib/lib/api/drift/drift-formatter.ts
439400
- var import_node_util5, import_cloudformation_diff3, import_client_cloudformation5, chalk23, DriftFormatter, ADDITION3, CONTEXT2, UPDATE3, REMOVAL3;
439585
+ var import_node_util6, import_cloudformation_diff3, import_client_cloudformation5, chalk23, DriftFormatter, ADDITION3, CONTEXT2, UPDATE3, REMOVAL3;
439401
439586
  var init_drift_formatter = __esm({
439402
439587
  "../toolkit-lib/lib/api/drift/drift-formatter.ts"() {
439403
439588
  "use strict";
439404
- import_node_util5 = require("node:util");
439589
+ import_node_util6 = require("node:util");
439405
439590
  import_cloudformation_diff3 = __toESM(require_lib11());
439406
439591
  import_client_cloudformation5 = __toESM(require_dist_cjs103());
439407
439592
  chalk23 = __toESM(require_source());
@@ -439433,7 +439618,7 @@ var init_drift_formatter = __esm({
439433
439618
  formatStackDrift() {
439434
439619
  const formatterOutput = this.formatStackDriftChanges(buildLogicalToPathMap(this.stack).toPath);
439435
439620
  const actualDrifts = this.resourceDriftResults.filter((d32) => (d32.StackResourceDriftStatus === "MODIFIED" || d32.StackResourceDriftStatus === "DELETED") && d32.ResourceType !== "AWS::CDK::Metadata");
439436
- const stackHeader = (0, import_node_util5.format)(`Stack ${chalk23.bold(this.stackName)}
439621
+ const stackHeader = (0, import_node_util6.format)(`Stack ${chalk23.bold(this.stackName)}
439437
439622
  `);
439438
439623
  if (actualDrifts.length === 0) {
439439
439624
  const finalResult2 = chalk23.green("No drift detected\n");
@@ -439555,15 +439740,15 @@ ${actualDrifts.length} resource${actualDrifts.length === 1 ? "" : "s"} ${actualD
439555
439740
  return "\n";
439556
439741
  }
439557
439742
  formatTreeDiff(propertyPath, difference2, isLast) {
439558
- let result2 = (0, import_node_util5.format)(
439743
+ let result2 = (0, import_node_util6.format)(
439559
439744
  " %s\u2500 %s %s\n",
439560
439745
  isLast ? "\u2514" : "\u251C",
439561
439746
  difference2.isAddition ? ADDITION3 : difference2.isRemoval ? REMOVAL3 : UPDATE3,
439562
439747
  propertyPath
439563
439748
  );
439564
439749
  if (difference2.isUpdate) {
439565
- result2 += (0, import_node_util5.format)(" \u251C\u2500 %s %s\n", REMOVAL3, chalk23.red(difference2.oldValue));
439566
- result2 += (0, import_node_util5.format)(" \u2514\u2500 %s %s\n", ADDITION3, chalk23.green(difference2.newValue));
439750
+ result2 += (0, import_node_util6.format)(" \u251C\u2500 %s %s\n", REMOVAL3, chalk23.red(difference2.oldValue));
439751
+ result2 += (0, import_node_util6.format)(" \u2514\u2500 %s %s\n", ADDITION3, chalk23.green(difference2.newValue));
439567
439752
  }
439568
439753
  return result2;
439569
439754
  }
@@ -439581,7 +439766,7 @@ async function detectStackDrift(cfn, ioHelper, stackName) {
439581
439766
  StackName: stackName
439582
439767
  });
439583
439768
  await ioHelper.defaults.trace(
439584
- (0, import_node_util6.format)("Detecting drift with ID %s for stack %s...", driftDetection.StackDriftDetectionId, stackName)
439769
+ (0, import_node_util7.format)("Detecting drift with ID %s for stack %s...", driftDetection.StackDriftDetectionId, stackName)
439585
439770
  );
439586
439771
  const driftStatus = await waitForDriftDetection(cfn, ioHelper, driftDetection.StackDriftDetectionId);
439587
439772
  if (driftStatus?.StackDriftStatus === "UNKNOWN") {
@@ -439631,11 +439816,11 @@ async function waitForDriftDetection(cfn, ioHelper, driftDetectionId) {
439631
439816
  await new Promise((resolve13) => setTimeout(resolve13, timeBetweenApiCalls));
439632
439817
  }
439633
439818
  }
439634
- var import_node_util6;
439819
+ var import_node_util7;
439635
439820
  var init_drift2 = __esm({
439636
439821
  "../toolkit-lib/lib/api/drift/drift.ts"() {
439637
439822
  "use strict";
439638
- import_node_util6 = require("node:util");
439823
+ import_node_util7 = require("node:util");
439639
439824
  init_toolkit_error();
439640
439825
  init_string_manipulation();
439641
439826
  __name(detectStackDrift, "detectStackDrift");
@@ -471154,7 +471339,7 @@ var init_runner_base = __esm({
471154
471339
 
471155
471340
  // lib/workers/common.ts
471156
471341
  function formatAssertionResults(results) {
471157
- return Object.entries(results).map(([id, result2]) => (0, import_util68.format)("%s%s", id, result2.status === "success" ? ` - ${result2.status}` : `
471342
+ return Object.entries(results).map(([id, result2]) => (0, import_util67.format)("%s%s", id, result2.status === "success" ? ` - ${result2.status}` : `
471158
471343
  ${result2.message}`)).join("\n ");
471159
471344
  }
471160
471345
  function formatError(error5) {
@@ -471166,11 +471351,11 @@ ${chalk28.gray("Cause: " + formatError(error5.cause))}`;
471166
471351
  }
471167
471352
  return `${name}: ${message2}`;
471168
471353
  }
471169
- var import_util68, chalk28;
471354
+ var import_util67, chalk28;
471170
471355
  var init_common14 = __esm({
471171
471356
  "lib/workers/common.ts"() {
471172
471357
  "use strict";
471173
- import_util68 = require("util");
471358
+ import_util67 = require("util");
471174
471359
  chalk28 = __toESM(require_source());
471175
471360
  init_logger();
471176
471361
  __name(formatAssertionResults, "formatAssertionResults");
package/package.json CHANGED
@@ -64,13 +64,13 @@
64
64
  "ts-jest": "^29.4.9",
65
65
  "typescript": "5.9",
66
66
  "@aws-cdk/aws-service-spec": "^0.1.180",
67
- "@aws-cdk/cdk-assets-lib": "1.4.7",
67
+ "@aws-cdk/cdk-assets-lib": "1.4.8",
68
68
  "@aws-cdk/cloud-assembly-api": "2.2.4",
69
- "@aws-cdk/cloud-assembly-schema": ">=53.25.0",
69
+ "@aws-cdk/cloud-assembly-schema": ">=53.27.0",
70
70
  "@aws-cdk/cloudformation-diff": "2.187.1",
71
- "@aws-cdk/toolkit-lib": "1.26.0",
71
+ "@aws-cdk/toolkit-lib": "1.26.2",
72
72
  "@aws-sdk/client-cloudformation": "^3",
73
- "aws-cdk": "2.1123.0",
73
+ "aws-cdk": "2.1124.1",
74
74
  "chalk": "^4",
75
75
  "chokidar": "^4",
76
76
  "fs-extra": "^11",
@@ -80,7 +80,7 @@
80
80
  },
81
81
  "dependencies": {
82
82
  "@aws-cdk/aws-service-spec": "0.1.180",
83
- "aws-cdk": "2.1123.0"
83
+ "aws-cdk": "2.1124.1"
84
84
  },
85
85
  "keywords": [
86
86
  "aws",
@@ -102,7 +102,7 @@
102
102
  "publishConfig": {
103
103
  "access": "public"
104
104
  },
105
- "version": "2.197.22",
105
+ "version": "2.197.24",
106
106
  "packageManager": "yarn@4.13.0",
107
107
  "types": "lib/index.d.ts",
108
108
  "//": "~~ Generated by projen. To modify, edit .projenrc.js and run \"yarn projen\"."