@shopify/create-app 4.7.0 → 4.8.0

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.
Files changed (40) hide show
  1. package/dist/{analytics-CVOS4X5D.js → analytics-AHLA7AZS.js} +12 -12
  2. package/dist/{analytics-A7XUM3DE.js → analytics-WH2T6QX3.js} +12 -12
  3. package/dist/{chunk-AOCVCJS6.js → chunk-2NFHHUNB.js} +7 -6
  4. package/dist/{chunk-XYNOPL42.js → chunk-3A6RVZAX.js} +2 -2
  5. package/dist/{chunk-LEQAULOW.js → chunk-6P5SC4GZ.js} +4 -4
  6. package/dist/{chunk-X2X377NR.js → chunk-CVCLWDTQ.js} +3 -3
  7. package/dist/{chunk-JMC4PKOZ.js → chunk-E3Q2X4JT.js} +9 -2
  8. package/dist/{chunk-B7LXQVGX.js → chunk-GUL6X3Z6.js} +19 -15
  9. package/dist/{chunk-A67PO4UO.js → chunk-KZ2RPAZP.js} +16 -16
  10. package/dist/{chunk-VJHCFG5K.js → chunk-NSZGKXWF.js} +2 -2
  11. package/dist/{chunk-FU4STSWX.js → chunk-NVF7ENTS.js} +16 -12
  12. package/dist/{chunk-YYJ6EVI6.js → chunk-OAQSBAWF.js} +3 -3
  13. package/dist/{chunk-ZPNNBR5Z.js → chunk-PPYQMZDW.js} +6 -6
  14. package/dist/{chunk-5LLHAM5N.js → chunk-RY5EN24F.js} +4 -4
  15. package/dist/{chunk-TGZSJFOF.js → chunk-SSXHJVVE.js} +9 -9
  16. package/dist/{chunk-HHKEZAAX.js → chunk-VQXC5OD5.js} +2 -2
  17. package/dist/{chunk-PK2M5CKS.js → chunk-YZ4NVX3R.js} +8 -8
  18. package/dist/{conf-store-NT7HUXZL.js → conf-store-J42SBUP3.js} +5 -5
  19. package/dist/{deprecations-37ZUNG4Z.js → deprecations-LQ5N6NY5.js} +8 -8
  20. package/dist/{environments-ISQBBMTF.js → environments-43DQFISL.js} +9 -9
  21. package/dist/{error-handler-GGBOXL7F.js → error-handler-HDQAL5WF.js} +12 -12
  22. package/dist/{fs-ZG73KWF7.js → fs-7VPG5DKY.js} +3 -3
  23. package/dist/hooks/postrun.js +4 -4
  24. package/dist/hooks/prerun.js +6 -6
  25. package/dist/index.js +32528 -23638
  26. package/dist/{is-global-DL3ZQWOO.js → is-global-NIA2NILS.js} +3 -3
  27. package/dist/{local-XAHKS4F6.js → local-QTXBNWG7.js} +2 -2
  28. package/dist/{metadata-4WOIDT2F.js → metadata-OKIQD7J3.js} +3 -3
  29. package/dist/{node-package-manager-JO3BBXYZ.js → node-package-manager-UGSWTVKV.js} +10 -10
  30. package/dist/{notifications-system-ZK44GBNG.js → notifications-system-WED4PTNQ.js} +13 -13
  31. package/dist/{os-XDQECFDE.js → os-GA2QX6HG.js} +4 -4
  32. package/dist/{output-2RGSJNA6.js → output-67BVQSOH.js} +3 -3
  33. package/dist/{system-KQM7CSD6.js → system-M2MQLB2V.js} +8 -8
  34. package/dist/tsconfig.tsbuildinfo +1 -1
  35. package/dist/{ui-UAVSRCJ7.js → ui-OLUB3ODI.js} +8 -8
  36. package/dist/{upgrade-QE6OI6PW.js → upgrade-VWPCOMAW.js} +14 -14
  37. package/dist/{version-AALUTWIR.js → version-BHYDBL3M.js} +2 -2
  38. package/dist/{version-6CVFB4SF.js → version-HXW64FOP.js} +9 -9
  39. package/oclif.manifest.json +1 -1
  40. package/package.json +3 -3
@@ -6,25 +6,25 @@ import {
6
6
  recordTiming,
7
7
  reportAnalyticsEvent,
8
8
  sendAnalyticsEventFromStdin
9
- } from "./chunk-B7LXQVGX.js";
9
+ } from "./chunk-GUL6X3Z6.js";
10
10
  import "./chunk-MSED5ZFM.js";
11
- import "./chunk-HHKEZAAX.js";
11
+ import "./chunk-VQXC5OD5.js";
12
12
  import "./chunk-G53O4PDO.js";
13
- import "./chunk-ZPNNBR5Z.js";
14
- import "./chunk-5LLHAM5N.js";
15
- import "./chunk-TGZSJFOF.js";
16
- import "./chunk-JMC4PKOZ.js";
17
- import "./chunk-YYJ6EVI6.js";
18
- import "./chunk-LEQAULOW.js";
13
+ import "./chunk-PPYQMZDW.js";
14
+ import "./chunk-RY5EN24F.js";
15
+ import "./chunk-SSXHJVVE.js";
16
+ import "./chunk-E3Q2X4JT.js";
17
+ import "./chunk-OAQSBAWF.js";
18
+ import "./chunk-6P5SC4GZ.js";
19
19
  import "./chunk-CM6ALOD7.js";
20
20
  import "./chunk-E43EDJOG.js";
21
21
  import "./chunk-ODCXYGJ2.js";
22
22
  import "./chunk-LBXDGVFS.js";
23
23
  import "./chunk-JGGOQOPO.js";
24
24
  import "./chunk-OQ3KXXGH.js";
25
- import "./chunk-VJHCFG5K.js";
26
- import "./chunk-PK2M5CKS.js";
27
- import "./chunk-X2X377NR.js";
25
+ import "./chunk-NSZGKXWF.js";
26
+ import "./chunk-YZ4NVX3R.js";
27
+ import "./chunk-CVCLWDTQ.js";
28
28
  import "./chunk-7OHJH7BF.js";
29
29
  import "./chunk-HNIAZN6U.js";
30
30
  import "./chunk-C3J4HVUN.js";
@@ -41,4 +41,4 @@ export {
41
41
  reportAnalyticsEvent,
42
42
  sendAnalyticsEventFromStdin
43
43
  };
44
- //# sourceMappingURL=analytics-CVOS4X5D.js.map
44
+ //# sourceMappingURL=analytics-AHLA7AZS.js.map
@@ -2,25 +2,25 @@ import {
2
2
  getEnvironmentData,
3
3
  getSensitiveEnvironmentData,
4
4
  startAnalytics
5
- } from "./chunk-B7LXQVGX.js";
5
+ } from "./chunk-GUL6X3Z6.js";
6
6
  import "./chunk-MSED5ZFM.js";
7
- import "./chunk-HHKEZAAX.js";
7
+ import "./chunk-VQXC5OD5.js";
8
8
  import "./chunk-G53O4PDO.js";
9
- import "./chunk-ZPNNBR5Z.js";
10
- import "./chunk-5LLHAM5N.js";
11
- import "./chunk-TGZSJFOF.js";
12
- import "./chunk-JMC4PKOZ.js";
13
- import "./chunk-YYJ6EVI6.js";
14
- import "./chunk-LEQAULOW.js";
9
+ import "./chunk-PPYQMZDW.js";
10
+ import "./chunk-RY5EN24F.js";
11
+ import "./chunk-SSXHJVVE.js";
12
+ import "./chunk-E3Q2X4JT.js";
13
+ import "./chunk-OAQSBAWF.js";
14
+ import "./chunk-6P5SC4GZ.js";
15
15
  import "./chunk-CM6ALOD7.js";
16
16
  import "./chunk-E43EDJOG.js";
17
17
  import "./chunk-ODCXYGJ2.js";
18
18
  import "./chunk-LBXDGVFS.js";
19
19
  import "./chunk-JGGOQOPO.js";
20
20
  import "./chunk-OQ3KXXGH.js";
21
- import "./chunk-VJHCFG5K.js";
22
- import "./chunk-PK2M5CKS.js";
23
- import "./chunk-X2X377NR.js";
21
+ import "./chunk-NSZGKXWF.js";
22
+ import "./chunk-YZ4NVX3R.js";
23
+ import "./chunk-CVCLWDTQ.js";
24
24
  import "./chunk-7OHJH7BF.js";
25
25
  import "./chunk-HNIAZN6U.js";
26
26
  import "./chunk-C3J4HVUN.js";
@@ -33,4 +33,4 @@ export {
33
33
  getSensitiveEnvironmentData,
34
34
  startAnalytics
35
35
  };
36
- //# sourceMappingURL=analytics-A7XUM3DE.js.map
36
+ //# sourceMappingURL=analytics-WH2T6QX3.js.map
@@ -1,18 +1,18 @@
1
1
  import {
2
2
  renderWarning
3
- } from "./chunk-TGZSJFOF.js";
3
+ } from "./chunk-SSXHJVVE.js";
4
4
  import {
5
5
  addSensitiveMetadata
6
- } from "./chunk-YYJ6EVI6.js";
6
+ } from "./chunk-OAQSBAWF.js";
7
7
  import {
8
8
  AbortError
9
- } from "./chunk-LEQAULOW.js";
9
+ } from "./chunk-6P5SC4GZ.js";
10
10
  import {
11
11
  fileExists,
12
12
  findPathUp,
13
13
  readFile,
14
14
  writeFile
15
- } from "./chunk-PK2M5CKS.js";
15
+ } from "./chunk-YZ4NVX3R.js";
16
16
  import {
17
17
  cwd
18
18
  } from "./chunk-C3J4HVUN.js";
@@ -1623,7 +1623,7 @@ function encodeToml(content) {
1623
1623
  }
1624
1624
 
1625
1625
  // ../cli-kit/dist/public/node/toml/toml-file.js
1626
- var import_toml_patch = __toESM(require_toml_patch()), TomlFileError = class extends AbortError {
1626
+ var import_toml_patch = __toESM(require_toml_patch(), 1), TomlFileError = class extends AbortError {
1627
1627
  path;
1628
1628
  constructor(path, message) {
1629
1629
  super(message), this.name = "TomlFileError", this.path = path;
@@ -1768,10 +1768,11 @@ async function environmentFilePath(fileName, options) {
1768
1768
  }
1769
1769
 
1770
1770
  export {
1771
+ decodeToml,
1771
1772
  require_toml_patch,
1772
1773
  TomlFileError,
1773
1774
  TomlFile,
1774
1775
  loadEnvironment,
1775
1776
  environmentFilePath
1776
1777
  };
1777
- //# sourceMappingURL=chunk-AOCVCJS6.js.map
1778
+ //# sourceMappingURL=chunk-2NFHHUNB.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  captureOutput,
3
3
  require_lib
4
- } from "./chunk-TGZSJFOF.js";
4
+ } from "./chunk-SSXHJVVE.js";
5
5
  import {
6
6
  require_semver
7
7
  } from "./chunk-OQ3KXXGH.js";
@@ -52,4 +52,4 @@ export {
52
52
  isPreReleaseVersion,
53
53
  isMajorVersionChange
54
54
  };
55
- //# sourceMappingURL=chunk-XYNOPL42.js.map
55
+ //# sourceMappingURL=chunk-3A6RVZAX.js.map
@@ -5,7 +5,7 @@ import {
5
5
  TokenizedString,
6
6
  stringifyMessage,
7
7
  tokenItemToString
8
- } from "./chunk-PK2M5CKS.js";
8
+ } from "./chunk-YZ4NVX3R.js";
9
9
  import {
10
10
  normalizePath
11
11
  } from "./chunk-C3J4HVUN.js";
@@ -102,7 +102,7 @@ async function handler(error) {
102
102
  let maybeError = error;
103
103
  fatal = new BugError(maybeError?.message ?? "Unknown error"), maybeError?.stack && (fatal.stack = maybeError?.stack);
104
104
  }
105
- let { renderFatalError } = await import("./ui-UAVSRCJ7.js");
105
+ let { renderFatalError } = await import("./ui-OLUB3ODI.js");
106
106
  return renderFatalError(fatal), Promise.resolve(error);
107
107
  }
108
108
  function errorMapper(error) {
@@ -136,7 +136,7 @@ function isExpectedApiError(error) {
136
136
  if (typeof candidate.response != "object" || candidate.response === null || candidate.request === void 0)
137
137
  return !1;
138
138
  let status = candidate.response.status;
139
- return status === 401 || status === 429 ? !0 : hasRateLimitCode(candidate.response.errors);
139
+ return status === 401 || status === 429 || status === 502 || status === 503 || status === 504 ? !0 : hasRateLimitCode(candidate.response.errors);
140
140
  }
141
141
  function cleanSingleStackTracePath(filePath) {
142
142
  return normalizePath(filePath).replace("file:/", "/").replace(/^\/?[A-Z]:/, "");
@@ -176,4 +176,4 @@ export {
176
176
  shouldReportErrorAsUnexpected,
177
177
  cleanSingleStackTracePath
178
178
  };
179
- //# sourceMappingURL=chunk-LEQAULOW.js.map
179
+ //# sourceMappingURL=chunk-6P5SC4GZ.js.map
@@ -174,11 +174,11 @@ var environmentVariables = {
174
174
  import { randomUUID } from "crypto";
175
175
  import { homedir as homedir2, networkInterfaces } from "os";
176
176
  async function lazyFileExists(path2) {
177
- let { fileExists } = await import("./fs-ZG73KWF7.js");
177
+ let { fileExists } = await import("./fs-7VPG5DKY.js");
178
178
  return fileExists(path2);
179
179
  }
180
180
  async function lazyExec(command, args) {
181
- let { exec } = await import("./system-KQM7CSD6.js");
181
+ let { exec } = await import("./system-M2MQLB2V.js");
182
182
  await exec(command, args);
183
183
  }
184
184
  function isTerminalInteractive() {
@@ -298,4 +298,4 @@ export {
298
298
  getThemeKitAccessDomain,
299
299
  opentelemetryDomain
300
300
  };
301
- //# sourceMappingURL=chunk-X2X377NR.js.map
301
+ //# sourceMappingURL=chunk-CVCLWDTQ.js.map
@@ -7,7 +7,7 @@ import {
7
7
  import {
8
8
  outputContent,
9
9
  outputDebug
10
- } from "./chunk-PK2M5CKS.js";
10
+ } from "./chunk-YZ4NVX3R.js";
11
11
  import {
12
12
  __commonJS,
13
13
  __require,
@@ -1383,9 +1383,16 @@ function makeUsernameFromId(userId) {
1383
1383
  }
1384
1384
 
1385
1385
  export {
1386
+ require_cross_spawn,
1387
+ stripFinalNewline,
1388
+ npmRunPathEnv,
1389
+ onetime_default,
1386
1390
  require_signal_exit,
1391
+ isStream,
1392
+ isWritableStream,
1393
+ require_merge_stream,
1387
1394
  execa,
1388
1395
  username,
1389
1396
  platformAndArch
1390
1397
  };
1391
- //# sourceMappingURL=chunk-JMC4PKOZ.js.map
1398
+ //# sourceMappingURL=chunk-E3Q2X4JT.js.map
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-MSED5ZFM.js";
4
4
  import {
5
5
  CLI_KIT_VERSION
6
- } from "./chunk-HHKEZAAX.js";
6
+ } from "./chunk-VQXC5OD5.js";
7
7
  import {
8
8
  FormData,
9
9
  fetch_blob_default,
@@ -12,7 +12,7 @@ import {
12
12
  import {
13
13
  getPackageManager,
14
14
  packageManagerFromUserAgent
15
- } from "./chunk-ZPNNBR5Z.js";
15
+ } from "./chunk-PPYQMZDW.js";
16
16
  import {
17
17
  Environment,
18
18
  cacheRetrieveOrRepopulate,
@@ -27,7 +27,7 @@ import {
27
27
  setCurrentSessionId,
28
28
  setSessions,
29
29
  timeIntervalToMilliseconds
30
- } from "./chunk-5LLHAM5N.js";
30
+ } from "./chunk-RY5EN24F.js";
31
31
  import {
32
32
  isCI,
33
33
  isWsl,
@@ -35,17 +35,17 @@ import {
35
35
  require_baseForOwn,
36
36
  require_stacktracey,
37
37
  sleep
38
- } from "./chunk-TGZSJFOF.js";
38
+ } from "./chunk-SSXHJVVE.js";
39
39
  import {
40
40
  platformAndArch
41
- } from "./chunk-JMC4PKOZ.js";
41
+ } from "./chunk-E3Q2X4JT.js";
42
42
  import {
43
43
  addPublicMetadata,
44
44
  addSensitiveMetadata,
45
45
  getAllPublicMetadata,
46
46
  getAllSensitiveMetadata,
47
47
  runWithTimer
48
- } from "./chunk-YYJ6EVI6.js";
48
+ } from "./chunk-OAQSBAWF.js";
49
49
  import {
50
50
  AbortError,
51
51
  AbortSilentError,
@@ -60,7 +60,7 @@ import {
60
60
  isPermissionCode,
61
61
  isRateLimitCode,
62
62
  shouldReportErrorAsUnexpected
63
- } from "./chunk-LEQAULOW.js";
63
+ } from "./chunk-6P5SC4GZ.js";
64
64
  import {
65
65
  require_lib
66
66
  } from "./chunk-E43EDJOG.js";
@@ -108,7 +108,7 @@ import {
108
108
  slugify,
109
109
  stringifyMessage,
110
110
  uniq
111
- } from "./chunk-PK2M5CKS.js";
111
+ } from "./chunk-YZ4NVX3R.js";
112
112
  import {
113
113
  alwaysLogAnalytics,
114
114
  alwaysLogMetrics,
@@ -126,7 +126,7 @@ import {
126
126
  sessionConstants,
127
127
  systemEnvironmentVariables,
128
128
  themeToken
129
- } from "./chunk-X2X377NR.js";
129
+ } from "./chunk-CVCLWDTQ.js";
130
130
  import {
131
131
  isTruthy
132
132
  } from "./chunk-HNIAZN6U.js";
@@ -62335,6 +62335,9 @@ init_cjs_shims();
62335
62335
  // ../cli-kit/dist/public/node/crypto.js
62336
62336
  init_cjs_shims();
62337
62337
  import crypto from "crypto";
62338
+ function sha256(str) {
62339
+ return crypto.createHash("sha256").update(str).digest();
62340
+ }
62338
62341
  function hashString(str) {
62339
62342
  return crypto.createHash("sha1").update(str).digest("hex");
62340
62343
  }
@@ -64488,7 +64491,7 @@ async function sendAnalyticsEvent(payload, skipMonorailAnalytics, skipMetricAnal
64488
64491
  }
64489
64492
  async function sendAnalyticsEventFromStdin() {
64490
64493
  try {
64491
- let { readStdinString } = await import("./system-KQM7CSD6.js"), payloadStr = await readStdinString();
64494
+ let { readStdinString } = await import("./system-M2MQLB2V.js"), payloadStr = await readStdinString();
64492
64495
  if (payloadStr === void 0)
64493
64496
  throw new Error("No analytics payload received from stdin");
64494
64497
  let { payload, skipMonorailAnalytics, skipMetricAnalytics } = JSON.parse(payloadStr);
@@ -64522,12 +64525,12 @@ async function reportAnalyticsEvent(options2) {
64522
64525
  outputDebug(outputContent`Skipping command analytics, payload: ${outputToken.json(payload)}`);
64523
64526
  return;
64524
64527
  }
64525
- let [{ platformAndArch: platformAndArch2 }, { isInsideContainer }] = await Promise.all([import("./os-XDQECFDE.js"), import("./system-KQM7CSD6.js")]), sendInBackground = !commandStartOptions?.requiresSyncAnalytics && platformAndArch2().platform !== "windows" && !ciPlatform().isCI && !isInsideContainer();
64528
+ let [{ platformAndArch: platformAndArch2 }, { isInsideContainer }] = await Promise.all([import("./os-GA2QX6HG.js"), import("./system-M2MQLB2V.js")]), sendInBackground = !commandStartOptions?.requiresSyncAnalytics && platformAndArch2().platform !== "windows" && !ciPlatform().isCI && !isInsideContainer();
64526
64529
  if (outputDebug(outputContent`Sending command analytics${sendInBackground ? " in background" : ""}, payload: ${outputToken.json(payload)}`), !sendInBackground) {
64527
64530
  await sendAnalyticsEvent(payload, skipMonorailAnalytics, skipMetricAnalytics);
64528
64531
  return;
64529
64532
  }
64530
- let { exec } = await import("./system-KQM7CSD6.js"), argv = process.argv;
64533
+ let { exec } = await import("./system-M2MQLB2V.js"), argv = process.argv;
64531
64534
  if (!argv[1])
64532
64535
  return;
64533
64536
  let nodeBinary = process.execPath, args = [argv[1], "send-analytics"], analyticsProcess = exec(nodeBinary, args, {
@@ -64592,7 +64595,7 @@ async function buildPayload({ config, errorMessage: errorMessage2, exitMode }) {
64592
64595
  }), sanitizePayload2(payload);
64593
64596
  }
64594
64597
  function sanitizePayload2(payload) {
64595
- let sanitizedPayloadString = JSON.stringify(payload).replace(/shptka_\w*/g, "*****").replace(/(--store-password(?:=|\s+))(?:"[^"]*"|'[^']*'|[^\s"]+)/g, "$1*****").replace(/((?:store-password|SHOPIFY_FLAG_STORE_PASSWORD)\\?":\\?")[^"\\]*/g, "$1*****");
64598
+ let sanitizedPayloadString = JSON.stringify(payload).replace(/shptka_\w*/g, "*****").replace(/(--store-password(?:=|\s+))(?:\\"[^"\\]*\\"|'[^']*'|(?:\\.|[^\s"\\])+)/g, "$1*****").replace(/((?:store-password|SHOPIFY_FLAG_STORE_PASSWORD)\\?":\\?")[^"\\]*/g, "$1*****").replace(/(--signup(?:=|\s+))(?:\\"[^"\\]*\\"|'[^']*'|(?:\\.|[^\s"\\])+)/g, "$1*****").replace(/((?:signup|SHOPIFY_FLAG_SIGNUP)\\?":\\?")[^"\\]*/g, "$1*****").replace(/(?<![\w-])(signup=)[^&\s"'\\]+/g, "$1*****");
64596
64599
  return JSON.parse(sanitizedPayloadString);
64597
64600
  }
64598
64601
  function recordTiming2(eventName) {
@@ -65720,7 +65723,7 @@ function unionArrayStrategy(destinationArray, sourceArray) {
65720
65723
  }
65721
65724
 
65722
65725
  // ../cli-kit/dist/public/common/object.js
65723
- var import_deepmerge = __toESM(require_cjs()), import_pickBy = __toESM(require_pickBy()), import_mapValues = __toESM(require_mapValues()), import_isEqual = __toESM(require_isEqual()), import_differenceWith = __toESM(require_differenceWith()), import_fromPairs = __toESM(require_fromPairs()), import_toPairs = __toESM(require_toPairs()), import_get = __toESM(require_get()), import_set = __toESM(require_set()), import_unset = __toESM(require_unset()), import_isEmpty = __toESM(require_isEmpty());
65726
+ var import_deepmerge = __toESM(require_cjs(), 1), import_pickBy = __toESM(require_pickBy(), 1), import_mapValues = __toESM(require_mapValues(), 1), import_isEqual = __toESM(require_isEqual(), 1), import_differenceWith = __toESM(require_differenceWith(), 1), import_fromPairs = __toESM(require_fromPairs(), 1), import_toPairs = __toESM(require_toPairs(), 1), import_get = __toESM(require_get(), 1), import_set = __toESM(require_set(), 1), import_unset = __toESM(require_unset(), 1), import_isEmpty = __toESM(require_isEmpty(), 1);
65724
65727
  function deepMergeObjects(lhs, rhs, arrayMergeStrategy = unionArrayStrategy) {
65725
65728
  return (0, import_deepmerge.default)(lhs, rhs, { arrayMerge: arrayMergeStrategy });
65726
65729
  }
@@ -66256,6 +66259,7 @@ function flagIncluded(flag, commandClass) {
66256
66259
  }
66257
66260
 
66258
66261
  export {
66262
+ sha256,
66259
66263
  hashString,
66260
66264
  fileHash,
66261
66265
  randomUUID,
@@ -66357,4 +66361,4 @@ mime-types/index.js:
66357
66361
  * MIT Licensed
66358
66362
  *)
66359
66363
  */
66360
- //# sourceMappingURL=chunk-B7LXQVGX.js.map
66364
+ //# sourceMappingURL=chunk-GUL6X3Z6.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  treeKill
3
- } from "./chunk-VJHCFG5K.js";
3
+ } from "./chunk-NSZGKXWF.js";
4
4
  import {
5
5
  init_cjs_shims
6
6
  } from "./chunk-3XNI6LP4.js";
@@ -26,22 +26,22 @@ function waitForPostRunHookAndExit() {
26
26
  }
27
27
  var hook = async ({ config, Command }) => {
28
28
  await detectStopCommand(Command);
29
- let metadata = await import("./metadata-4WOIDT2F.js"), { commandStartOptions } = metadata.getAllSensitiveMetadata();
29
+ let metadata = await import("./metadata-OKIQD7J3.js"), { commandStartOptions } = metadata.getAllSensitiveMetadata();
30
30
  commandStartOptions && await metadata.addSensitiveMetadata(() => ({
31
31
  commandStartOptions: {
32
32
  ...commandStartOptions,
33
33
  endTime: (/* @__PURE__ */ new Date()).getTime()
34
34
  }
35
35
  }));
36
- let { postrun: deprecationsHook } = await import("./deprecations-37ZUNG4Z.js");
36
+ let { postrun: deprecationsHook } = await import("./deprecations-LQ5N6NY5.js");
37
37
  deprecationsHook(Command);
38
- let { outputDebug } = await import("./output-2RGSJNA6.js"), command = Command.id.replace(/:/g, " ");
38
+ let { outputDebug } = await import("./output-67BVQSOH.js"), command = Command.id.replace(/:/g, " ");
39
39
  outputDebug(`Completed command ${command}`), !command.includes("notifications") && !command.includes("upgrade") && !command.includes("send-analytics") && await autoUpgradeIfNeeded();
40
- let { reportAnalyticsEvent } = await import("./analytics-CVOS4X5D.js");
40
+ let { reportAnalyticsEvent } = await import("./analytics-AHLA7AZS.js");
41
41
  await reportAnalyticsEvent({ config, exitMode: "ok" }), postRunHookCompleted = !0;
42
42
  };
43
43
  async function autoUpgradeIfNeeded() {
44
- let { versionToAutoUpgrade, warnIfUpgradeAvailable } = await import("./upgrade-QE6OI6PW.js"), newerVersion = versionToAutoUpgrade();
44
+ let { versionToAutoUpgrade, warnIfUpgradeAvailable } = await import("./upgrade-VWPCOMAW.js"), newerVersion = versionToAutoUpgrade();
45
45
  if (!newerVersion) {
46
46
  await warnIfUpgradeAvailable();
47
47
  return;
@@ -49,7 +49,7 @@ async function autoUpgradeIfNeeded() {
49
49
  if (process.env.SHOPIFY_CLI_FORCE_AUTO_UPGRADE === "1")
50
50
  await performAutoUpgrade(newerVersion);
51
51
  else {
52
- let { runAtMinimumInterval } = await import("./conf-store-NT7HUXZL.js");
52
+ let { runAtMinimumInterval } = await import("./conf-store-J42SBUP3.js");
53
53
  await runAtMinimumInterval("auto-upgrade", { days: 1 }, async () => {
54
54
  await performAutoUpgrade(newerVersion);
55
55
  });
@@ -57,11 +57,11 @@ async function autoUpgradeIfNeeded() {
57
57
  }
58
58
  async function performAutoUpgrade(newerVersion) {
59
59
  let [{ CLI_KIT_VERSION }, { isMajorVersionChange }, { outputWarn, outputDebug }, { getOutputUpdateCLIReminder, runCLIUpgrade, hasBlockingAutoUpgradeNotification }, metadata] = await Promise.all([
60
- import("./version-AALUTWIR.js"),
61
- import("./version-6CVFB4SF.js"),
62
- import("./output-2RGSJNA6.js"),
63
- import("./upgrade-QE6OI6PW.js"),
64
- import("./metadata-4WOIDT2F.js")
60
+ import("./version-BHYDBL3M.js"),
61
+ import("./version-HXW64FOP.js"),
62
+ import("./output-67BVQSOH.js"),
63
+ import("./upgrade-VWPCOMAW.js"),
64
+ import("./metadata-OKIQD7J3.js")
65
65
  ]);
66
66
  if (isMajorVersionChange(CLI_KIT_VERSION, newerVersion)) {
67
67
  outputWarn(getOutputUpdateCLIReminder(newerVersion, !0)), await metadata.addPublicMetadata(() => ({
@@ -81,8 +81,8 @@ async function performAutoUpgrade(newerVersion) {
81
81
  let errorMessage = `Auto-upgrade failed: ${error}`;
82
82
  outputDebug(errorMessage), outputWarn(getOutputUpdateCLIReminder(newerVersion)), await metadata.addPublicMetadata(() => ({ env_auto_upgrade_success: !1 }));
83
83
  let [{ sendErrorToBugsnag }, { inferPackageManagerForGlobalCLI }] = await Promise.all([
84
- import("./error-handler-GGBOXL7F.js"),
85
- import("./is-global-DL3ZQWOO.js")
84
+ import("./error-handler-HDQAL5WF.js"),
85
+ import("./is-global-NIA2NILS.js")
86
86
  ]), enrichedError = Object.assign(new Error(errorMessage), {
87
87
  packageManager: inferPackageManagerForGlobalCLI(),
88
88
  platform: process.platform,
@@ -96,7 +96,7 @@ async function detectStopCommand(commandClass) {
96
96
  if (commandClass && "analyticsStopCommand" in commandClass && typeof commandClass.analyticsStopCommand == "function") {
97
97
  let stopCommand = commandClass.analyticsStopCommand();
98
98
  if (stopCommand) {
99
- let metadata = await import("./metadata-4WOIDT2F.js"), { commandStartOptions } = metadata.getAllSensitiveMetadata();
99
+ let metadata = await import("./metadata-OKIQD7J3.js"), { commandStartOptions } = metadata.getAllSensitiveMetadata();
100
100
  if (!commandStartOptions)
101
101
  return;
102
102
  await metadata.addSensitiveMetadata(() => ({
@@ -114,4 +114,4 @@ export {
114
114
  waitForPostRunHookAndExit,
115
115
  hook
116
116
  };
117
- //# sourceMappingURL=chunk-A67PO4UO.js.map
117
+ //# sourceMappingURL=chunk-KZ2RPAZP.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  outputDebug
3
- } from "./chunk-PK2M5CKS.js";
3
+ } from "./chunk-YZ4NVX3R.js";
4
4
  import {
5
5
  init_cjs_shims
6
6
  } from "./chunk-3XNI6LP4.js";
@@ -96,4 +96,4 @@ function buildProcessTree(parentPid, tree, pidsToProcess, spawnChildProcessesLis
96
96
  export {
97
97
  treeKill
98
98
  };
99
- //# sourceMappingURL=chunk-VJHCFG5K.js.map
99
+ //# sourceMappingURL=chunk-NSZGKXWF.js.map
@@ -2,29 +2,29 @@ import {
2
2
  external_exports,
3
3
  fetch,
4
4
  jsonOutputEnabled
5
- } from "./chunk-B7LXQVGX.js";
5
+ } from "./chunk-GUL6X3Z6.js";
6
6
  import {
7
7
  CLI_KIT_VERSION
8
- } from "./chunk-HHKEZAAX.js";
8
+ } from "./chunk-VQXC5OD5.js";
9
9
  import {
10
10
  versionSatisfies
11
- } from "./chunk-ZPNNBR5Z.js";
11
+ } from "./chunk-PPYQMZDW.js";
12
12
  import {
13
13
  cacheRetrieve,
14
14
  cacheStore
15
- } from "./chunk-5LLHAM5N.js";
15
+ } from "./chunk-RY5EN24F.js";
16
16
  import {
17
17
  exec,
18
18
  renderError,
19
19
  renderInfo,
20
20
  renderWarning
21
- } from "./chunk-TGZSJFOF.js";
21
+ } from "./chunk-SSXHJVVE.js";
22
22
  import {
23
23
  AbortSilentError
24
- } from "./chunk-LEQAULOW.js";
24
+ } from "./chunk-6P5SC4GZ.js";
25
25
  import {
26
26
  outputDebug
27
- } from "./chunk-PK2M5CKS.js";
27
+ } from "./chunk-YZ4NVX3R.js";
28
28
  import {
29
29
  isTruthy
30
30
  } from "./chunk-HNIAZN6U.js";
@@ -58,19 +58,23 @@ var URL = "https://cdn.shopify.com/static/cli/notifications.json", EMPTY_CACHE_M
58
58
  "hydrogen:init",
59
59
  "cache:clear",
60
60
  "send-analytics"
61
- ];
61
+ ], LOOPBACK_HOSTNAMES = ["127.0.0.1", "localhost", "::1", "[::1]"];
62
62
  function url() {
63
63
  let envUrl = process.env.SHOPIFY_CLI_NOTIFICATIONS_URL;
64
64
  if (envUrl)
65
65
  try {
66
- if (new globalThis.URL(envUrl).protocol === "https:")
66
+ let parsedUrl = new globalThis.URL(envUrl);
67
+ if (isAllowedNotificationsUrl(parsedUrl))
67
68
  return envUrl;
68
- outputDebug(`The notifications URL provided via SHOPIFY_CLI_NOTIFICATIONS_URL (${envUrl}) is not secure (https). Falling back to default.`);
69
+ outputDebug(`The notifications URL provided via SHOPIFY_CLI_NOTIFICATIONS_URL (${envUrl}) must use https, or http with a loopback host. Falling back to default.`);
69
70
  } catch {
70
71
  outputDebug(`The notifications URL provided via SHOPIFY_CLI_NOTIFICATIONS_URL (${envUrl}) is not a valid URL. Falling back to default.`);
71
72
  }
72
73
  return URL;
73
74
  }
75
+ function isAllowedNotificationsUrl(parsedUrl) {
76
+ return parsedUrl.protocol === "https:" ? !0 : parsedUrl.protocol === "http:" && LOOPBACK_HOSTNAMES.includes(parsedUrl.hostname);
77
+ }
74
78
  var NotificationSchema = external_exports.object({
75
79
  id: external_exports.string(),
76
80
  message: external_exports.string(),
@@ -105,7 +109,7 @@ async function showNotificationsIfNeeded(currentSurfaces, environment = process.
105
109
  throw new AbortSilentError();
106
110
  let errorMessage = `Error showing notifications: ${error.message}`;
107
111
  outputDebug(errorMessage);
108
- let { sendErrorToBugsnag } = await import("./error-handler-GGBOXL7F.js");
112
+ let { sendErrorToBugsnag } = await import("./error-handler-HDQAL5WF.js");
109
113
  await sendErrorToBugsnag(errorMessage, "unexpected_error");
110
114
  }
111
115
  }
@@ -219,4 +223,4 @@ export {
219
223
  filterNotifications,
220
224
  stringifyFilters
221
225
  };
222
- //# sourceMappingURL=chunk-FU4STSWX.js.map
226
+ //# sourceMappingURL=chunk-NVF7ENTS.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isUnitTest
3
- } from "./chunk-X2X377NR.js";
3
+ } from "./chunk-CVCLWDTQ.js";
4
4
  import {
5
5
  init_cjs_shims
6
6
  } from "./chunk-3XNI6LP4.js";
@@ -32,7 +32,7 @@ function createRuntimeMetadataContainer(defaultPublicMetadata = {}) {
32
32
  try {
33
33
  await getAndSet();
34
34
  } catch (error) {
35
- let { sendErrorToBugsnag } = await import("./error-handler-GGBOXL7F.js");
35
+ let { sendErrorToBugsnag } = await import("./error-handler-HDQAL5WF.js");
36
36
  await sendErrorToBugsnag(error, "unexpected_error");
37
37
  }
38
38
  }, durationStack = [];
@@ -75,4 +75,4 @@ export {
75
75
  addSensitiveMetadata,
76
76
  runWithTimer
77
77
  };
78
- //# sourceMappingURL=chunk-YYJ6EVI6.js.map
78
+ //# sourceMappingURL=chunk-OAQSBAWF.js.map
@@ -1,18 +1,18 @@
1
1
  import {
2
2
  cacheRetrieve,
3
3
  cacheRetrieveOrRepopulate
4
- } from "./chunk-5LLHAM5N.js";
4
+ } from "./chunk-RY5EN24F.js";
5
5
  import {
6
6
  AbortController,
7
7
  exec
8
- } from "./chunk-TGZSJFOF.js";
8
+ } from "./chunk-SSXHJVVE.js";
9
9
  import {
10
10
  runWithTimer
11
- } from "./chunk-YYJ6EVI6.js";
11
+ } from "./chunk-OAQSBAWF.js";
12
12
  import {
13
13
  AbortError,
14
14
  BugError
15
- } from "./chunk-LEQAULOW.js";
15
+ } from "./chunk-6P5SC4GZ.js";
16
16
  import {
17
17
  require_semver
18
18
  } from "./chunk-OQ3KXXGH.js";
@@ -27,7 +27,7 @@ import {
27
27
  outputToken,
28
28
  readFile,
29
29
  writeFile
30
- } from "./chunk-PK2M5CKS.js";
30
+ } from "./chunk-YZ4NVX3R.js";
31
31
  import {
32
32
  dirname,
33
33
  joinPath
@@ -344,4 +344,4 @@ export {
344
344
  writePackageJSON,
345
345
  inferPackageManager
346
346
  };
347
- //# sourceMappingURL=chunk-ZPNNBR5Z.js.map
347
+ //# sourceMappingURL=chunk-PPYQMZDW.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  AbortError,
3
3
  BugError
4
- } from "./chunk-LEQAULOW.js";
4
+ } from "./chunk-6P5SC4GZ.js";
5
5
  import {
6
6
  mimicFunction
7
7
  } from "./chunk-CM6ALOD7.js";
@@ -13,12 +13,12 @@ import {
13
13
  outputContent,
14
14
  outputDebug,
15
15
  unixFileIsOwnedByCurrentUser
16
- } from "./chunk-PK2M5CKS.js";
16
+ } from "./chunk-YZ4NVX3R.js";
17
17
  import {
18
18
  envPaths,
19
19
  environmentVariables,
20
20
  isUnitTest
21
- } from "./chunk-X2X377NR.js";
21
+ } from "./chunk-CVCLWDTQ.js";
22
22
  import {
23
23
  dirname
24
24
  } from "./chunk-C3J4HVUN.js";
@@ -6114,4 +6114,4 @@ export {
6114
6114
  getCachedPartnerAccountStatus,
6115
6115
  setCachedPartnerAccountStatus
6116
6116
  };
6117
- //# sourceMappingURL=chunk-5LLHAM5N.js.map
6117
+ //# sourceMappingURL=chunk-RY5EN24F.js.map