@go-to-k/cdkd 0.284.54 → 0.284.55

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.
@@ -1,5 +1,5 @@
1
1
  import { a as getLiveRenderer, d as generateResourceNameWithFallback, f as getCurrentStackName, h as withStackName, l as applyDefaultNameForFallback, n as getLogger, p as looksLikeCdkdGeneratedName, u as generateResourceName } from "./logger-zRrlbaQt.js";
2
- import { t as getCdkdVersion } from "./version-DLRgymoe.js";
2
+ import { t as getCdkdVersion } from "./version-DD5yHFTJ.js";
3
3
  import { randomUUID } from "node:crypto";
4
4
  import { CreateBucketCommand, DeleteObjectCommand, DeleteObjectsCommand, GetBucketLocationCommand, GetObjectCommand, HeadBucketCommand, HeadObjectCommand, ListObjectsV2Command, NoSuchKey, PutBucketEncryptionCommand, PutBucketPolicyCommand, PutObjectCommand, PutPublicAccessBlockCommand, S3Client, S3ServiceException } from "@aws-sdk/client-s3";
5
5
  import { CloudControlClient, CreateResourceCommand, DeleteResourceCommand, GetResourceCommand, GetResourceRequestStatusCommand, ListResourcesCommand, UpdateResourceCommand } from "@aws-sdk/client-cloudcontrol";
@@ -18490,7 +18490,7 @@ var CloudControlProvider = class {
18490
18490
  if (context?.finalSnapshotIdentifier !== void 0) throw new ProvisioningError(`${logicalId} (${resourceType}) requires a final snapshot (DeletionPolicy: Snapshot), but the Cloud Control API delete route has no final-snapshot parameter. Re-run with --skip-final-snapshot after snapshotting manually, or retain the resource.`, resourceType, logicalId, physicalId);
18491
18491
  if (context?.removeProtection === true && resourceType === "AWS::AutoScaling::AutoScalingGroup") {
18492
18492
  this.logger.debug(`Delegating protected AutoScalingGroup ${logicalId} delete to the SDK ASGProvider (Cloud Control cannot force-delete a protected ASG)`);
18493
- const { ASGProvider } = await import("./asg-provider-BaNTIjU4.js").then((n) => n.n);
18493
+ const { ASGProvider } = await import("./asg-provider-nddX-RVm.js").then((n) => n.n);
18494
18494
  return await new ASGProvider().delete(logicalId, physicalId, resourceType, _properties, context);
18495
18495
  }
18496
18496
  const isProtectedEc2Instance = context?.removeProtection === true && resourceType === "AWS::EC2::Instance";
@@ -19233,13 +19233,28 @@ var CloudControlProvider = class {
19233
19233
  *
19234
19234
  * 4. **The handler force-quits when it is the LAST listener.** Property 3 gets
19235
19235
  * the watch armed only under a command with a shutdown path, but that path
19236
- * is not live for the command's whole duration: `destroy.ts` registers no
19237
- * SIGINT handler of its own, and `destroy-runner.ts` removes its one in a
19238
- * `finally` — so between two stacks of a multi-stack destroy the shared
19239
- * handler is the ONLY listener. Merely latching there SWALLOWS the Ctrl-C:
19240
- * the process does not exit, `draining` is never set, `result.interrupted`
19241
- * stays false, and the loop proceeds to delete the NEXT stack after the user
19242
- * asked to stop — this file's own headline failure, one layer out.
19236
+ * is not live for the command's whole duration. The case that motivated it:
19237
+ * `destroy.ts` registered no SIGINT handler of its own, and
19238
+ * `destroy-runner.ts` removes its one in a `finally` — so between two stacks
19239
+ * of a multi-stack destroy the shared handler was the ONLY listener. Merely
19240
+ * latching there SWALLOWS the Ctrl-C: the process does not exit, `draining`
19241
+ * is never set, `result.interrupted` stays false, and the loop proceeds to
19242
+ * delete the NEXT stack after the user asked to stop — this file's own
19243
+ * headline failure, one layer out.
19244
+ *
19245
+ * Issue #2117 closed THAT instance from the command side: `destroy.ts` and
19246
+ * `state.ts` now hold a command-scoped handler for their whole run
19247
+ * (`watchCommandInterrupt`, `src/utils/interrupt-signals.ts`), so this
19248
+ * handler is no longer last during a destroy and no longer fires there.
19249
+ * That is the improvement rather than a loss — the force-quit exited 130
19250
+ * with the lock stranded and without stopping the loop gracefully. Note the
19251
+ * dependency runs BOTH ways: because this handler is a latch rather than a
19252
+ * graceful owner, that watch must NOT treat its presence as "someone else
19253
+ * will handle this" (it subtracts `interruptWatchListenerCount()` for
19254
+ * exactly that reason), or the swallow above returns one window inward.
19255
+ * The remaining population here is the commands that register no handler at
19256
+ * all — `import` / `export` / `scrub` / `orphan` / `drift` /
19257
+ * `state refresh-observed`.
19243
19258
  *
19244
19259
  * So when no other listener remains, the handler restores exactly what Node
19245
19260
  * would have done with no listener at all. That is deliberately not a second
@@ -19314,7 +19329,10 @@ let sigintLatched = false;
19314
19329
  * Production never assigns either, and neither condition may be weakened to
19315
19330
  * accommodate tests: a command without a shutdown path really must keep Node's
19316
19331
  * default terminate, and a swallowed Ctrl-C in a multi-stack destroy really is
19317
- * a blocker. `cdkd drift --revert` and `cdkd destroy` are the live instances.
19332
+ * a blocker. `cdkd drift --revert` is the live instance of the first. The second
19333
+ * was `cdkd destroy`, until issue #2117 gave both destroy commands a
19334
+ * command-scoped handler of their own; the force-quit's remaining population is
19335
+ * the commands that register none at all (see property 4).
19318
19336
  *
19319
19337
  * `commandOwnsInterrupts` exists because a provider suite never runs a COMMAND,
19320
19338
  * so every interrupt test would otherwise exercise the UNARMED path while
@@ -19434,6 +19452,15 @@ function endCommandInterruptScope() {
19434
19452
  }
19435
19453
  resetInterruptWatchLatch();
19436
19454
  }
19455
+ /**
19456
+ * How many process SIGINT listeners this module owns: 0 before arming, 1 after.
19457
+ *
19458
+ * Exported so a test can pin both polarities of property 3 without reaching
19459
+ * into module state or counting listeners it does not own.
19460
+ */
19461
+ function interruptWatchListenerCount() {
19462
+ return sharedSigintHandler === void 0 ? 0 : 1;
19463
+ }
19437
19464
 
19438
19465
  //#endregion
19439
19466
  //#region src/state/state-prefix.ts
@@ -29871,5 +29898,5 @@ var DeployEngine = class {
29871
29898
  };
29872
29899
 
29873
29900
  //#endregion
29874
- export { endCommandInterruptScope as $, clearBucketRegionCache as $n, importableOutputKeys as $t, renderStatefulReason as A, synthesisStatusMessage as An, isMarkedNonRetryable as Ar, maskSecretsInError as At, exportAliasCollisionScrubWarning as B, stateBucketExistenceConfirmed as Bn, s3BucketWebsiteUrl as Bt, isFinalSnapshotError as C, getDockerCmd as Cn, StackTerminationProtectionError as Cr, STATE_SOURCED_CROSS_GENERATION_RULES as Ct, extractDeploymentEventError as D, AssetManifestLoader as Dn, isCdkdError as Dr, dynamicReferenceTokens as Dt, makeCanonicalizePropertiesFn as E, runDockerStreaming as En, formatError as Er, createSecretMasker as Et, green as F, resolveCaptureObservedState as Fn, producerRegionsFromState as Ft, collectInlinePolicyNamesManagedBySiblings as G, findLargeInlineResources as Gn, withRetry as Gt, secretBearingStateKeyWarning as H, CFN_TEMPLATE_BODY_LIMIT as Hn, DiffCalculator as Ht, red as I, resolveSkipPrefix as In, s3BucketArn as It, findActionableSilentDrops as J, PARTITION_TABLE as Jn, LockManager as Jt, clearOnUpdateRemoval as K, uploadCfnTemplate as Kn, DagBuilder as Kt, yellow as L, resolveStateBucketWithDefault as Ln, s3BucketDomainName as Lt, bold as M, getLegacyStateBucketName as Mn, isThrottlingError as Mr, redactSecretsForState as Mt, cyan as N, resolveApp as Nn, markNonRetryable as Nr, scrubResourceRecord as Nt, MULTI_REGION_RECREATE_BLOCKED_TYPES as O, getDockerImageBySourceHash as On, normalizeAwsError as Or, errorCauseChain as Ot, gray as P, resolveAutoAssetStorage as Pn, __exportAll as Pr, classifyReplaySecretRegion as Pt, beginCommandInterruptScope as Q, processStackMessages as Qn, exportNamesCarriedFrom as Qt, collectDeclaredOutputNames as R, resolveStateBucketWithDefaultAndSource as Rn, s3BucketDualStackDomainName as Rt, createPreDeleteFinalSnapshot as S, formatDockerLoginError as Sn, StackHasActiveImportsError as Sr, requireConfigString as St, unsupportedFinalSnapshotError as T, runDockerForeground as Tn, SynthesisError as Tr, TEMPLATE_SOURCED_RULES as Tt, stateKeySecretExposure as U, CFN_TEMPLATE_URL_LIMIT as Un, INTRINSIC_KEYS as Ut, isExportAliasCollision as V, warnDeprecatedNoPrefixCliFlag as Vn, applyRoleArnIfSet as Vt, IAMRoleProvider as W, MIGRATE_TMP_PREFIX as Wn, describeTypeWithThrottleRetry as Wt, CUSTOM_RESOURCE_RESPONSE_PREFIX as X, derivePartitionAndUrlSuffix as Xn, S3StateBackend as Xt, findSilentDropProperties as Y, canonicalizeRegion as Yn, displaySafe as Yt, DEFAULT_STATE_PREFIX as Z, AssemblyReader as Zn, rebuildClientForBucketRegion as Zt, computeImplicitDeleteEdges as _, validateAssetBucketName as _n, NestedStackChildDirectDestroyError as _r, configStringRefusal as _t, DeploymentEventsStore as a, buildAssetRedirectMap as an, AssetError as ar, isTerminationProtectionPropagationError as at, buildFinalSnapshotIdentifier as b, buildDockerImage as bn, ResourceTimeoutError as br, requireConfigArray as bt, replayFailedOperations as c, rewriteTemplateAssetReferences as cn, CrossAccountSecretRefusalError as cr, cfnRefValueFromPhysicalId as ct, updatePartialReason as d, AssetModeResolver as dn, DynamicReferenceRegionAmbiguousError as dr, WAFv2WebACLProvider as dt, importableOutputs as en, resolveBucketRegion as er, isInterruptedWaitError as et, UNSPECIFIED_SKIP_REASON as f, BOOTSTRAP_MARKER_PREFIX as fn, LocalInvokeBuildError as fr, normalizeAwsTagsToCfn as ft, IMPLICIT_DELETE_DEPENDENCIES as g, readBootstrapMarkerBody as gn, MissingCdkCliError as gr, configBooleanRefusal as gt, maskingRetryLogger as h, parseBootstrapMarker as hn, LockError as hr, coerceCfnBoolean as ht, DeploymentEventsReader as i, WorkGraph as in, setAwsClients as ir, disableInstanceApiTermination as it, formatResourceLine as j, getDefaultStateBucketName as jn, isRetryableTransientError as jr, maskSecretsInText as jt, isStatefulRecreateTargetSync as k, Synthesizer as kn, withErrorHandling as kr, isSingleDynamicReferenceToken as kt, replayRollback as l, escapeRegExp$1 as ln, DependencyError as lr, getAccountInfo as lt, withResourceDeadline as m, getBootstrapMarkerKey as mn, LocalStartServiceError as mr, assertRegionMatch as mt, DEFAULT_RESOURCE_WARN_AFTER_MS as n, AssetPublisher as nn, getAwsClients as nr, CloudControlProvider as nt, planFailedOps as o, createAssetRedirectResolver as on, CdkdError as or, IntrinsicFunctionResolver as ot, deleteSkipReason as p, ensureAssetStorage as pn, LocalMigrateError as pr, resolveExplicitPhysicalId as pt, ProviderRegistry as q, expectedOwnerParam as qn, TemplateParser as qt, DeployEngine as r, stringifyValue as rn, resetAwsClients as rr, slowCcOperationTimeoutMs as rt, planRollback as s, loadPublishableAssetManifest as sn, ConfigError as sr, carriesDynamicReference as st, DEFAULT_RESOURCE_TIMEOUT_MS as t, shouldRetainResource as tn, AwsClients as tr, startInterruptWatch as tt, updatePartialMessage as u, stripControlChars as un, DeployCancelledError as ur, refStateLookupFromResource as ut, ATOMIC_FINAL_SNAPSHOT_TYPES as v, validateContainerRepoName as vn, PartialFailureError as vr, readConfigString as vt, refusesFinalSnapshot as w, partitionSensitiveEnv as wn, StateError as wr, STATE_SOURCED_READBACK_RULES as wt, ccRoutedFinalSnapshotError as x, dockerSpawnEnvWithSensitive as xn, ResourceUpdateNotSupportedError as xr, requireConfigObject as xt, PRE_DELETE_SNAPSHOT_TYPES as y, buildDenyExternalAccessPolicy as yn, ProvisioningError as yr, replayWarn as yt, collectPublishedOutputNames as z, resolveUseCdkBootstrapAssets as zn, s3BucketRegionalDomainName as zt };
29875
- //# sourceMappingURL=deploy-engine-B9SrF2-R.js.map
29901
+ export { endCommandInterruptScope as $, processStackMessages as $n, exportNamesCarriedFrom as $t, renderStatefulReason as A, Synthesizer as An, withErrorHandling as Ar, isSingleDynamicReferenceToken as At, exportAliasCollisionScrubWarning as B, resolveUseCdkBootstrapAssets as Bn, s3BucketRegionalDomainName as Bt, isFinalSnapshotError as C, formatDockerLoginError as Cn, StackHasActiveImportsError as Cr, requireConfigString as Ct, extractDeploymentEventError as D, runDockerStreaming as Dn, formatError as Dr, createSecretMasker as Dt, makeCanonicalizePropertiesFn as E, runDockerForeground as En, SynthesisError as Er, TEMPLATE_SOURCED_RULES as Et, green as F, resolveAutoAssetStorage as Fn, __exportAll as Fr, classifyReplaySecretRegion as Ft, collectInlinePolicyNamesManagedBySiblings as G, MIGRATE_TMP_PREFIX as Gn, describeTypeWithThrottleRetry as Gt, secretBearingStateKeyWarning as H, warnDeprecatedNoPrefixCliFlag as Hn, applyRoleArnIfSet as Ht, red as I, resolveCaptureObservedState as In, producerRegionsFromState as It, findActionableSilentDrops as J, expectedOwnerParam as Jn, TemplateParser as Jt, clearOnUpdateRemoval as K, findLargeInlineResources as Kn, withRetry as Kt, yellow as L, resolveSkipPrefix as Ln, s3BucketArn as Lt, bold as M, getDefaultStateBucketName as Mn, isRetryableTransientError as Mr, maskSecretsInText as Mt, cyan as N, getLegacyStateBucketName as Nn, isThrottlingError as Nr, redactSecretsForState as Nt, MULTI_REGION_RECREATE_BLOCKED_TYPES as O, AssetManifestLoader as On, isCdkdError as Or, dynamicReferenceTokens as Ot, gray as P, resolveApp as Pn, markNonRetryable as Pr, scrubResourceRecord as Pt, beginCommandInterruptScope as Q, AssemblyReader as Qn, rebuildClientForBucketRegion as Qt, collectDeclaredOutputNames as R, resolveStateBucketWithDefault as Rn, s3BucketDomainName as Rt, createPreDeleteFinalSnapshot as S, dockerSpawnEnvWithSensitive as Sn, ResourceUpdateNotSupportedError as Sr, requireConfigObject as St, unsupportedFinalSnapshotError as T, partitionSensitiveEnv as Tn, StateError as Tr, STATE_SOURCED_READBACK_RULES as Tt, stateKeySecretExposure as U, CFN_TEMPLATE_BODY_LIMIT as Un, DiffCalculator as Ut, isExportAliasCollision as V, stateBucketExistenceConfirmed as Vn, s3BucketWebsiteUrl as Vt, IAMRoleProvider as W, CFN_TEMPLATE_URL_LIMIT as Wn, INTRINSIC_KEYS as Wt, CUSTOM_RESOURCE_RESPONSE_PREFIX as X, canonicalizeRegion as Xn, displaySafe as Xt, findSilentDropProperties as Y, PARTITION_TABLE as Yn, LockManager as Yt, DEFAULT_STATE_PREFIX as Z, derivePartitionAndUrlSuffix as Zn, S3StateBackend as Zt, computeImplicitDeleteEdges as _, readBootstrapMarkerBody as _n, MissingCdkCliError as _r, configBooleanRefusal as _t, DeploymentEventsStore as a, WorkGraph as an, setAwsClients as ar, disableInstanceApiTermination as at, buildFinalSnapshotIdentifier as b, buildDenyExternalAccessPolicy as bn, ProvisioningError as br, replayWarn as bt, replayFailedOperations as c, loadPublishableAssetManifest as cn, ConfigError as cr, carriesDynamicReference as ct, updatePartialReason as d, stripControlChars as dn, DeployCancelledError as dr, refStateLookupFromResource as dt, importableOutputKeys as en, clearBucketRegionCache as er, interruptWatchListenerCount as et, UNSPECIFIED_SKIP_REASON as f, AssetModeResolver as fn, DynamicReferenceRegionAmbiguousError as fr, WAFv2WebACLProvider as ft, IMPLICIT_DELETE_DEPENDENCIES as g, parseBootstrapMarker as gn, LockError as gr, coerceCfnBoolean as gt, maskingRetryLogger as h, getBootstrapMarkerKey as hn, LocalStartServiceError as hr, assertRegionMatch as ht, DeploymentEventsReader as i, stringifyValue as in, resetAwsClients as ir, slowCcOperationTimeoutMs as it, formatResourceLine as j, synthesisStatusMessage as jn, isMarkedNonRetryable as jr, maskSecretsInError as jt, isStatefulRecreateTargetSync as k, getDockerImageBySourceHash as kn, normalizeAwsError as kr, errorCauseChain as kt, replayRollback as l, rewriteTemplateAssetReferences as ln, CrossAccountSecretRefusalError as lr, cfnRefValueFromPhysicalId as lt, withResourceDeadline as m, ensureAssetStorage as mn, LocalMigrateError as mr, resolveExplicitPhysicalId as mt, DEFAULT_RESOURCE_WARN_AFTER_MS as n, shouldRetainResource as nn, AwsClients as nr, startInterruptWatch as nt, planFailedOps as o, buildAssetRedirectMap as on, AssetError as or, isTerminationProtectionPropagationError as ot, deleteSkipReason as p, BOOTSTRAP_MARKER_PREFIX as pn, LocalInvokeBuildError as pr, normalizeAwsTagsToCfn as pt, ProviderRegistry as q, uploadCfnTemplate as qn, DagBuilder as qt, DeployEngine as r, AssetPublisher as rn, getAwsClients as rr, CloudControlProvider as rt, planRollback as s, createAssetRedirectResolver as sn, CdkdError as sr, IntrinsicFunctionResolver as st, DEFAULT_RESOURCE_TIMEOUT_MS as t, importableOutputs as tn, resolveBucketRegion as tr, isInterruptedWaitError as tt, updatePartialMessage as u, escapeRegExp$1 as un, DependencyError as ur, getAccountInfo as ut, ATOMIC_FINAL_SNAPSHOT_TYPES as v, validateAssetBucketName as vn, NestedStackChildDirectDestroyError as vr, configStringRefusal as vt, refusesFinalSnapshot as w, getDockerCmd as wn, StackTerminationProtectionError as wr, STATE_SOURCED_CROSS_GENERATION_RULES as wt, ccRoutedFinalSnapshotError as x, buildDockerImage as xn, ResourceTimeoutError as xr, requireConfigArray as xt, PRE_DELETE_SNAPSHOT_TYPES as y, validateContainerRepoName as yn, PartialFailureError as yr, readConfigString as yt, collectPublishedOutputNames as z, resolveStateBucketWithDefaultAndSource as zn, s3BucketDualStackDomainName as zt };
29902
+ //# sourceMappingURL=deploy-engine-B1tSPv8F.js.map