Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gardener is broken on Node v6.x #2612

Closed
ghost opened this issue Aug 5, 2016 · 2 comments
Closed

Gardener is broken on Node v6.x #2612

ghost opened this issue Aug 5, 2016 · 2 comments
Labels
Type: Technical issue Improve something that users won't notice

Comments

@ghost
Copy link

ghost commented Aug 5, 2016

Gardener appears broken on Node v6.2.0. NPM's call-level interface has changed – specifically, npm.commands.install(dir, url, fn) has changed to npm.commands.install(dir, args, fn), where args can be [ url ]. Audit all uses of the npm module for compatibility with the latest version, and fix API incompatibilities. Either (a) branch a new major version of Gardener for Node v6.x, or (b) add a runtime version check so that the same version of Gardener works on all versions of Node and NPM.

$ node -v
v6.2.0

$ cat /srv/storage/gardener/logs/startup.log
Gardener started successfully. Logs in: /srv/storage/gardener/logs
/srv/software/medic-core/v1.6.1/x64/lib/node_modules/npm/node_modules/aproba/index.js:26
    if (!typeCheck(args[ii])) throw invalidType(ii, typeLabel, args[ii])
                              ^

Error: Argument #2: Expected array but got string
    at EventEmitter.install (/srv/software/medic-core/v1.6.1/x64/lib/node_modules/npm/lib/install.js:179:3)
    at Object.commandCache.(anonymous function) (/srv/software/medic-core/v1.6.1/x64/lib/node_modules/npm/lib/npm.js:114:13)
    at Object.exports.install (/srv/software/gardener/v1.1.1/lib/npm.js:41:18)
    at Array.async.auto.install_package (/srv/software/gardener/v1.1.1/lib/processes.js:313:25)
    at /srv/software/medic-core/v1.6.1/x64/lib/node_modules/async/lib/async.js:596:38
    at _arrayEach (/srv/software/medic-core/v1.6.1/x64/lib/node_modules/async/lib/async.js:85:13)
    at Object.async.auto (/srv/software/medic-core/v1.6.1/x64/lib/node_modules/async/lib/async.js:554:9)
    at _install (/srv/software/gardener/v1.1.1/lib/processes.js:291:11)
    at /srv/software/gardener/v1.1.1/lib/processes.js:135:17
    at /srv/software/gardener/v1.1.1/lib/processes.js:448:20
@ghost ghost added 1 - Scheduled Type: Technical issue Improve something that users won't notice labels Aug 5, 2016
@ghost ghost added this to the August 8th - August 22nd milestone Aug 5, 2016
@ghost ghost self-assigned this Aug 5, 2016
@ghost ghost added 2 - Active Work and removed 1 - Scheduled labels Aug 8, 2016
ghost pushed a commit to medic/medic-os that referenced this issue Aug 9, 2016
This much-simpler-than-expected compatibility fix tested out okay
on both NPM v3.8.9 and NPM v2.5.1. No runtime check required. I'll
test this out thoroughly and then submit an upstream PR.

Toward medic/cht-core#2612.
@ghost ghost added 3 - Code Review and removed 2 - Active Work labels Aug 9, 2016
@ghost
Copy link
Author

ghost commented Aug 9, 2016

The resolution in medic/medic-os@b984811 tests out okay; sending a PR.

@ghost
Copy link
Author

ghost commented Aug 9, 2016

Upstreamed to garden20/gardener#30 for review.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Technical issue Improve something that users won't notice
Projects
None yet
Development

No branches or pull requests

1 participant