sst 2.1.11 → 2.1.13

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,4 +1,4 @@
1
- const PACKAGE_MATCH = ["sst", "aws-cdk", "@aws-cdk", "constructs"];
1
+ const PACKAGE_MATCH = ["sst", "astro-sst", "aws-cdk", "@aws-cdk", "constructs"];
2
2
  const FIELDS = ["dependencies", "devDependencies"];
3
3
  export const update = (program) => program.command("update [version]", "Update your SST and CDK packages", (yargs) => yargs.positional("version", {
4
4
  type: "string",
@@ -45,7 +45,8 @@ export const update = (program) => program.command("update [version]", "Update y
45
45
  if (!PACKAGE_MATCH.some((x) => pkg.startsWith(x)))
46
46
  continue;
47
47
  const desired = (() => {
48
- if (pkg === "sst")
48
+ // Both sst and astro-sst should be sharing the same version
49
+ if (["sst", "astro-sst"].includes(pkg))
49
50
  return metadata.version;
50
51
  if (pkg === "constructs")
51
52
  return metadata.dependencies.constructs;
@@ -402,12 +402,12 @@ export interface NodeJSProps {
402
402
  /**
403
403
  * Configure format
404
404
  *
405
- * @default "cjs"
405
+ * @default "esm"
406
406
  *
407
407
  * @example
408
408
  * ```js
409
409
  * nodejs: {
410
- * format: "esm"
410
+ * format: "cjs"
411
411
  * }
412
412
  * ```
413
413
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sst",
3
- "version": "2.1.11",
3
+ "version": "2.1.13",
4
4
  "bin": {
5
5
  "sst": "cli/sst.js"
6
6
  },
package/sst.mjs CHANGED
@@ -3180,8 +3180,10 @@ async function monitor(stack) {
3180
3180
  "Resource creation cancelled"
3181
3181
  ) || event.ResourceStatusReason.includes(
3182
3182
  "Resource update cancelled"
3183
- ) || event.ResourceStatusReason?.includes(
3183
+ ) || event.ResourceStatusReason.includes(
3184
3184
  "Resource creation Initiated"
3185
+ ) || event.ResourceStatusReason.startsWith(
3186
+ "The following resource(s) failed to"
3185
3187
  ))
3186
3188
  continue;
3187
3189
  errors[event.LogicalResourceId] = event.ResourceStatusReason;
@@ -3200,7 +3202,11 @@ async function monitor(stack) {
3200
3202
  "Resource creation cancelled"
3201
3203
  ) || resource.ResourceStatusReason?.includes(
3202
3204
  "Resource update cancelled"
3203
- ) || resource.ResourceStatusReason?.includes("Resource creation Initiated"))
3205
+ ) || resource.ResourceStatusReason?.includes(
3206
+ "Resource creation Initiated"
3207
+ ) || resource.ResourceStatusReason?.startsWith(
3208
+ "The following resource(s) failed to"
3209
+ ))
3204
3210
  continue;
3205
3211
  if (resource.ResourceStatusReason)
3206
3212
  errors[resource.LogicalResourceId] = resource.ResourceStatusReason;
@@ -7434,7 +7440,7 @@ function secrets(program2) {
7434
7440
  }
7435
7441
 
7436
7442
  // src/cli/commands/update.ts
7437
- var PACKAGE_MATCH = ["sst", "aws-cdk", "@aws-cdk", "constructs"];
7443
+ var PACKAGE_MATCH = ["sst", "astro-sst", "aws-cdk", "@aws-cdk", "constructs"];
7438
7444
  var FIELDS = ["dependencies", "devDependencies"];
7439
7445
  var update = (program2) => program2.command(
7440
7446
  "update [version]",
@@ -7483,7 +7489,7 @@ var update = (program2) => program2.command(
7483
7489
  if (!PACKAGE_MATCH.some((x) => pkg.startsWith(x)))
7484
7490
  continue;
7485
7491
  const desired = (() => {
7486
- if (pkg === "sst")
7492
+ if (["sst", "astro-sst"].includes(pkg))
7487
7493
  return metadata3.version;
7488
7494
  if (pkg === "constructs")
7489
7495
  return metadata3.dependencies.constructs;
package/stacks/monitor.js CHANGED
@@ -81,7 +81,9 @@ export async function monitor(stack) {
81
81
  if (event.ResourceStatusReason) {
82
82
  if (event.ResourceStatusReason.includes("Resource creation cancelled") ||
83
83
  event.ResourceStatusReason.includes("Resource update cancelled") ||
84
- event.ResourceStatusReason?.includes("Resource creation Initiated"))
84
+ event.ResourceStatusReason.includes("Resource creation Initiated") ||
85
+ // ie. The following resource(s) failed to update: [MyResource10A5921D].
86
+ event.ResourceStatusReason.startsWith("The following resource(s) failed to"))
85
87
  continue;
86
88
  errors[event.LogicalResourceId] = event.ResourceStatusReason;
87
89
  }
@@ -97,7 +99,9 @@ export async function monitor(stack) {
97
99
  for (const resource of resources.StackResources || []) {
98
100
  if (resource.ResourceStatusReason?.includes("Resource creation cancelled") ||
99
101
  resource.ResourceStatusReason?.includes("Resource update cancelled") ||
100
- resource.ResourceStatusReason?.includes("Resource creation Initiated"))
102
+ resource.ResourceStatusReason?.includes("Resource creation Initiated") ||
103
+ // ie. The following resource(s) failed to update: [MyResource10A5921D].
104
+ resource.ResourceStatusReason?.startsWith("The following resource(s) failed to"))
101
105
  continue;
102
106
  if (resource.ResourceStatusReason)
103
107
  errors[resource.LogicalResourceId] = resource.ResourceStatusReason;