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

Yarn 0.23.2 uses Array.include which is not present in node 4 #3138

Closed
MiguelMadero opened this issue Apr 13, 2017 · 5 comments
Closed

Yarn 0.23.2 uses Array.include which is not present in node 4 #3138

MiguelMadero opened this issue Apr 13, 2017 · 5 comments

Comments

@MiguelMadero
Copy link
Contributor

MiguelMadero commented Apr 13, 2017

Do you want to request a feature or report a bug?

What is the current behavior?

yarn tries to use Array.include which is not present in node 4.

If the current behavior is a bug, please provide the steps to reproduce.

  1. curl -o- -L https://yarnpkg.com/install.sh | bash
  2. nvm use 4.8.2
  3. yarn global add bower

What is the expected behavior?

It should install the dependencies and avoid depending on language features/apis not available on node 4.

Please mention your node.js, yarn and operating system version.

node --version 
v4.8.1
y~/code-zenefits/z-buttons [mmadero/test-travis|✔] 
03:37 PM $ yarn --version 
0.23.2

Full log

03:50 PM $ vim /Users/mmadero/.config/yarn/global/yarn-error.log 



































  stringstream@~0.0.4:
    version "0.0.5"
    resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878"

  strip-ansi@^3.0.0:
    version "3.0.1"
    resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf"
    dependencies:
      ansi-regex "^2.0.0"

  supports-color@^2.0.0:
    version "2.0.0"
    resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7"

  throttleit@^1.0.0:
    version "1.0.0"
    resolved "https://registry.yarnpkg.com/throttleit/-/throttleit-1.0.0.tgz#9e785836daf46743145a5984b6268d828528ac6c"

  tough-cookie@~2.3.0:
    version "2.3.2"
    resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.2.tgz#f081f76e4c85720e6c37a5faced737150d84072a"
    dependencies:
      punycode "^1.4.1"

  tunnel-agent@~0.4.1:
    version "0.4.3"
    resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.4.3.tgz#6373db76909fe570e08d73583365ed828a74eeeb"

  tweetnacl@^0.14.3, tweetnacl@~0.14.0:
    version "0.14.5"
    resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64"

  typedarray@~0.0.5:
    version "0.0.6"
    resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"

  util-deprecate@~1.0.1:
    version "1.0.2"
    resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf"

  uuid@^3.0.0:
    version "3.0.1"
    resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.0.1.tgz#6544bba2dfda8c1cf17e629a3a305e2bb1fee6c1"

  [email protected]:
    version "1.3.6"
    resolved "https://registry.yarnpkg.com/verror/-/verror-1.3.6.tgz#cff5df12946d297d2baaefaa2689e25be01c005c"
    dependencies:
      extsprintf "1.0.2"

  which@~1.2.10:
    version "1.2.14"
    resolved "https://registry.yarnpkg.com/which/-/which-1.2.14.tgz#9a87c4378f03e827cecaf1acdf56c736c01c14e5"
    dependencies:
      isexe "^2.0.0"

  xtend@^4.0.0:
    version "4.0.1"
    resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af"

  [email protected]:
    version "2.4.1"
    resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.4.1.tgz#9528f442dab1b2284e58b4379bb194e22e0c4005"
    dependencies:
      fd-slicer "~1.0.1"

Trace:
  TypeError: args.includes is not a function
      at /Users/mmadero/.yarn/lib-legacy/cli/commands/global.js:289:16
      at next (native)
      at step (/Users/mmadero/.yarn/node_modules/babel-runtime/helpers/asyncToGenerator.js:17:30)
      at /Users/mmadero/.yarn/node_modules/babel-runtime/helpers/asyncToGenerator.js:28:13
      at run (/Users/mmadero/.yarn/node_modules/core-js/library/modules/es6.promise.js:87:22)
      at /Users/mmadero/.yarn/node_modules/core-js/library/modules/es6.promise.js:100:28
      at module.exports.flush (/Users/mmadero/.yarn/node_modules/core-js/library/modules/_microtask.js:18:9)
      at nextTickCallbackWith0Args (node.js:489:9)
      at process._tickCallback (node.js:418:13)

@qifali
Copy link

qifali commented Apr 14, 2017

I face the same problem, my node version is v5.10.1

@jasonadkison
Copy link

Also having this issue with nodejs 4.8.2 and yarn 0.23.2.

@simonihmig
Copy link

Seeing the same, here is a Travis build with node 4: https://travis-ci.org/kaliber5/ember-bootstrap/jobs/221796901#L225

@MiguelMadero
Copy link
Contributor Author

You can have a look at #3139 that fixes the problem

@markelog
Copy link

markelog commented Apr 16, 2017

It seems originally release with this error happened because this specific line doesn't have any tests, since otherwise CI would pick it up?

I think it would be a good idea not only to fix it but add tests for it as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants