Error updating on master branch "npm install"

Hello,

Since the update yesterday, I get this error every time I try to run bench update --reset:

“npm ERR! Object.entries is not a function
npm ERR! A complete log of this run can be found in:
npm ERR! /home/frappe/.npm/_logs/2018-05-09T14_16_44_528Z-debug.log
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 11, in
load_entry_point(‘bench’, ‘console_scripts’, ‘bench’)()
File “/home/frappe/.bench/bench/cli.py”, line 40, in cli
bench_command()
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 722, in call
return self.main(*args, **kwargs)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 697, in main
rv = self.invoke(ctx)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 1066, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 895, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/usr/local/lib/python2.7/dist-packages/click/core.py”, line 535, in invoke
return callback(*args, **kwargs)
File “/home/frappe/.bench/bench/commands/update.py”, line 60, in update
_update(pull, patch, build, bench, auto, restart_supervisor, restart_systemd, requirements, no_backup, force=force, reset=reset)
File “/home/frappe/.bench/bench/commands/update.py”, line 77, in _update
update_node_packages(bench_path=bench_path)
File “/home/frappe/.bench/bench/utils.py”, line 441, in update_node_packages
update_npm_packages(bench_path)
File “/home/frappe/.bench/bench/utils.py”, line 488, in update_npm_packages
exec_cmd(‘npm install’, cwd=bench_path)
File “/home/frappe/.bench/bench/utils.py”, line 153, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: npm install”

Here is the tail content of the npm error log

“1104 silly install saveToDependencies
1105 verbose saving []
1106 timing audit submit Completed in 1387ms
1107 http fetch POST 200 https://registry.npmjs.org/-/npm/v1/security/audits/quick 1386ms
1108 timing audit body Completed in 1ms
1109 info lifecycle undefined~preshrinkwrap: undefined
1110 info lifecycle undefined~shrinkwrap: undefined
1111 verbose shrinkwrap skipping write for package-lock.json because there were no changes.
1112 info lifecycle undefined~postshrinkwrap: undefined
1113 warn frappe@ No description
1114 warn optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.3 (node_modules/fsevents):
1115 warn notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.3: wanted {“os”:“darwin”,“arch”:“any”} (current: {“os”:“linux”,“arch”:“x64”})
1116 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid OS: darwin
1116 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Valid Arch: any
1116 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual OS: linux
1116 verbose notsup SKIPPING OPTIONAL DEPENDENCY: Actual Arch: x64
1117 silly install printInstalled
1118 verbose stack TypeError: Object.entries is not a function
1118 verbose stack at Object.report [as install] (/usr/lib/node_modules/npm/node_modules/npm-audit-report/reporters/install.js:27:31)
1118 verbose stack at Promise (/usr/lib/node_modules/npm/node_modules/npm-audit-report/index.js:18:46)
1118 verbose stack at report (/usr/lib/node_modules/npm/node_modules/npm-audit-report/index.js:17:10)
1118 verbose stack at Object.printInstallReport (/usr/lib/node_modules/npm/lib/install/audit.js:87:10)
1118 verbose stack at Object.Installer.printInstalledForHuman (/usr/lib/node_modules/npm/lib/install.js:847:31)
1118 verbose stack at Bluebird.try.then (/usr/lib/node_modules/npm/lib/install.js:774:19)
1118 verbose stack at tryCatcher (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
1118 verbose stack at Promise._settlePromiseFromHandler (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:512:31)
1118 verbose stack at Promise._settlePromise (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:569:18)
1118 verbose stack at Promise._settlePromise0 (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:614:10)
1118 verbose stack at Promise._settlePromises (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:693:18)
1118 verbose stack at Async._drainQueue (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:133:16)
1118 verbose stack at Async._drainQueues (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:143:10)
1118 verbose stack at Immediate.Async.drainQueues (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:17:14)
1118 verbose stack at runCallback (timers.js:672:20)
1118 verbose stack at tryOnImmediate (timers.js:645:5)
1119 verbose cwd /home/frappe/frappe-bench
1120 verbose Linux 4.13.0-41-generic
1121 verbose argv “/usr/bin/node” “/usr/bin/npm” “install”
1122 verbose node v6.14.2
1123 verbose npm v6.0.0
1124 error Object.entries is not a function
1125 verbose exit [ 1, true ]”

Any ideas?

bench update today solved the issue.