netlify-cli 10.6.0 → 10.6.3

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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "netlify-cli",
3
3
  "description": "Netlify command line tool",
4
- "version": "10.6.0",
4
+ "version": "10.6.3",
5
5
  "author": "Netlify Inc.",
6
6
  "contributors": [
7
7
  "Abraham Schilling <AbrahamSchilling@gmail.com> (https://gitlab.com/n4bb12)",
@@ -212,9 +212,9 @@
212
212
  "prettier": "--ignore-path .gitignore --loglevel=warn \"{src,tools,scripts,site,tests,.github}/**/*.{mjs,cjs,js,md,yml,json,html}\" \"*.{mjs,cjs,js,yml,json,html}\" \".*.{mjs,cjs,js,yml,json,html}\" \"!CHANGELOG.md\" \"!npm-shrinkwrap.json\" \"!**/*/package-lock.json\" \"!.github/**/*.md\""
213
213
  },
214
214
  "dependencies": {
215
- "@netlify/build": "^27.1.6",
216
- "@netlify/config": "^18.0.2",
217
- "@netlify/edge-bundler": "^1.4.0",
215
+ "@netlify/build": "^27.3.1",
216
+ "@netlify/config": "^18.1.0",
217
+ "@netlify/edge-bundler": "^1.4.1",
218
218
  "@netlify/framework-info": "^9.1.0",
219
219
  "@netlify/local-functions-proxy": "^1.1.1",
220
220
  "@netlify/plugins-list": "^6.28.0",
@@ -105,9 +105,9 @@
105
105
  }
106
106
  },
107
107
  "node_modules/stripe": {
108
- "version": "9.9.0",
109
- "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.9.0.tgz",
110
- "integrity": "sha512-UBuHzKoEaHnTv2h65cIcYE0vse7at8CFlwjl/KS8I7piekMKa1lRTA5R2O4eXMp5wllWQbPF/UoLzTfjjcdBqA==",
108
+ "version": "9.10.0",
109
+ "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.10.0.tgz",
110
+ "integrity": "sha512-ZRJenPgLQk1xdDnTpLNDl06WOD342YsRnMay03D6jkozKTjuWcfVZB/hng4eYfAdPDF07RNpNT+CX6AT2Ir7ew==",
111
111
  "dependencies": {
112
112
  "@types/node": ">=8.1.0",
113
113
  "qs": "^6.10.3"
@@ -184,9 +184,9 @@
184
184
  }
185
185
  },
186
186
  "stripe": {
187
- "version": "9.9.0",
188
- "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.9.0.tgz",
189
- "integrity": "sha512-UBuHzKoEaHnTv2h65cIcYE0vse7at8CFlwjl/KS8I7piekMKa1lRTA5R2O4eXMp5wllWQbPF/UoLzTfjjcdBqA==",
187
+ "version": "9.10.0",
188
+ "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.10.0.tgz",
189
+ "integrity": "sha512-ZRJenPgLQk1xdDnTpLNDl06WOD342YsRnMay03D6jkozKTjuWcfVZB/hng4eYfAdPDF07RNpNT+CX6AT2Ir7ew==",
190
190
  "requires": {
191
191
  "@types/node": ">=8.1.0",
192
192
  "qs": "^6.10.3"
@@ -105,9 +105,9 @@
105
105
  }
106
106
  },
107
107
  "node_modules/stripe": {
108
- "version": "9.9.0",
109
- "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.9.0.tgz",
110
- "integrity": "sha512-UBuHzKoEaHnTv2h65cIcYE0vse7at8CFlwjl/KS8I7piekMKa1lRTA5R2O4eXMp5wllWQbPF/UoLzTfjjcdBqA==",
108
+ "version": "9.10.0",
109
+ "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.10.0.tgz",
110
+ "integrity": "sha512-ZRJenPgLQk1xdDnTpLNDl06WOD342YsRnMay03D6jkozKTjuWcfVZB/hng4eYfAdPDF07RNpNT+CX6AT2Ir7ew==",
111
111
  "dependencies": {
112
112
  "@types/node": ">=8.1.0",
113
113
  "qs": "^6.10.3"
@@ -184,9 +184,9 @@
184
184
  }
185
185
  },
186
186
  "stripe": {
187
- "version": "9.9.0",
188
- "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.9.0.tgz",
189
- "integrity": "sha512-UBuHzKoEaHnTv2h65cIcYE0vse7at8CFlwjl/KS8I7piekMKa1lRTA5R2O4eXMp5wllWQbPF/UoLzTfjjcdBqA==",
187
+ "version": "9.10.0",
188
+ "resolved": "https://registry.npmjs.org/stripe/-/stripe-9.10.0.tgz",
189
+ "integrity": "sha512-ZRJenPgLQk1xdDnTpLNDl06WOD342YsRnMay03D6jkozKTjuWcfVZB/hng4eYfAdPDF07RNpNT+CX6AT2Ir7ew==",
190
190
  "requires": {
191
191
  "@types/node": ">=8.1.0",
192
192
  "qs": "^6.10.3"
@@ -5,7 +5,7 @@ const { cwd, env } = require('process')
5
5
  const getAvailablePort = require('get-port')
6
6
  const { v4: generateUUID } = require('uuid')
7
7
 
8
- const { NETLIFYDEVERR, NETLIFYDEVWARN, chalk, log } = require('../../utils/command-helpers')
8
+ const { NETLIFYDEVERR, NETLIFYDEVWARN, chalk, error, log } = require('../../utils/command-helpers')
9
9
  const { getGeoLocation } = require('../geo-location')
10
10
  const { getPathInProject } = require('../settings')
11
11
  const { startSpinner, stopSpinner } = require('../spinner')
@@ -22,8 +22,11 @@ const LOCAL_HOST = '127.0.0.1'
22
22
  const getDownloadUpdateFunctions = () => {
23
23
  let spinner
24
24
 
25
- const onAfterDownload = () => {
26
- stopSpinner({ spinner })
25
+ /**
26
+ * @param {Error=} error_
27
+ */
28
+ const onAfterDownload = (error_) => {
29
+ stopSpinner({ error: Boolean(error_), spinner })
27
30
  }
28
31
 
29
32
  const onBeforeDownload = () => {
@@ -74,16 +77,24 @@ const initializeProxy = async ({
74
77
  projectDir,
75
78
  })
76
79
  const hasEdgeFunctions = userFunctionsPath !== undefined || internalFunctions.length !== 0
80
+ let hasServerError = false
77
81
 
78
82
  return async (req) => {
79
- if (req.headers[headers.Passthrough] !== undefined || !hasEdgeFunctions) {
83
+ if (req.headers[headers.Passthrough] !== undefined || !hasEdgeFunctions || hasServerError) {
80
84
  return
81
85
  }
82
86
 
83
- const [geoLocation, { registry }] = await Promise.all([
84
- getGeoLocation({ mode: geolocationMode, offline, state }),
85
- server,
86
- ])
87
+ let promiseResult
88
+
89
+ try {
90
+ promiseResult = await Promise.all([getGeoLocation({ mode: geolocationMode, offline, state }), server])
91
+ } catch (error_) {
92
+ error(error_.message, { exit: false })
93
+ hasServerError = true
94
+ return
95
+ }
96
+
97
+ const [geoLocation, { registry }] = promiseResult
87
98
 
88
99
  // Setting header with geolocation.
89
100
  req.headers[headers.Geo] = JSON.stringify(geoLocation)