react-static icon indicating copy to clipboard operation
react-static copied to clipboard

Error with netlify´s continuous deployment

Open kations opened this issue 8 years ago • 6 comments

Seems like netlify have a old node Version? Maybe someone knows how get around this error.

Btw thanks for the great tool!

4:32:17 PM: => [✓] App Bundled: 9436.293ms 4:32:17 PM: => Exporting Routes... 4:32:18 PM: TypeError: Object.values is not a function at _callee$ (/opt/build/repo/node_modules/react-static/lib/static.js:178:32) at tryCatch (/opt/build/repo/node_modules/regenerator-runtime/runtime.js:62:40) at GeneratorFunctionPrototype.invoke [as _invoke] (/opt/build/repo/node_modules/regenerator-runtime/runtime.js:296:22) at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (/opt/build/repo/node_modules/regenerator-runtime/runtime.js:114:21) at step (/opt/build/repo/node_modules/react-static/lib/static.js:120:191) at /opt/build/repo/node_modules/react-static/lib/static.js:120:437 at /opt/build/repo/node_modules/react-static/lib/static.js:120:99 at /opt/build/repo/node_modules/react-static/lib/static.js:206:30 at Array.map (native) at _callee4$ (/opt/build/repo/node_modules/react-static/lib/static.js:150:46) at tryCatch (/opt/build/repo/node_modules/regenerator-runtime/runtime.js:62:40) at GeneratorFunctionPrototype.invoke [as _invoke] (/opt/build/repo/node_modules/regenerator-runtime/runtime.js:296:22) at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (/opt/build/repo/node_modules/regenerator-runtime/runtime.js:114:21) at step (/opt/build/repo/node_modules/react-static/lib/static.js:120:191) at /opt/build/repo/node_modules/react-static/lib/static.js:120:361 4:32:18 PM: Cached NPM modules 4:32:18 PM: Saved Yarn cache 4:32:18 PM: Build complete: exit code: 1 4:32:18 PM: Cleaning up docker container 4:32:18 PM: Error running command: Build script returned non-zero exit code: 1 4:32:19 PM: An error occurred while building the site, skipping the deploy and cache refresh. 4:32:19 PM: Build script returned non-zero exit code: 1 4:32:20 PM: Finished processing build request in 1m4.121329136s

kations avatar Dec 28 '17 15:12 kations

Hi @kations! Object.values was removed in [email protected], so try upgrading to that.

EmilTholin avatar Dec 28 '17 15:12 EmilTholin

@EmilTholin i have tried it with "react-static": "^4.8.3", in package.json also checked "Clear build cache" on netlify. Still the same Error

kations avatar Dec 29 '17 10:12 kations

Hi, @kations. Met this issue today. Setting a 'Build environment variables' in netlify site configuration helped. (https://www.netlify.com/docs/continuous-deployment/#set-node-ruby-or-python-version)

I have set this to NODE_VERSION 8.1.2

Hope that will help you.

Renkoru avatar Dec 29 '17 20:12 Renkoru

@Renkoru thanks that did the trick, thank you

kations avatar Dec 30 '17 10:12 kations

.nvmrc file in the root of your project with just 8 in it will also make Netlify use the latest version of Node 8 for the builds.

hmeissner avatar Jan 03 '18 11:01 hmeissner

A new version has been released that alleviates this problem until we release a new major version. Cheers!

tannerlinsley avatar Jan 16 '18 20:01 tannerlinsley