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

tools: move eslint and install babel-eslint #17820

Merged
merged 4 commits into from
Jan 11, 2018
Merged

Conversation

targos
Copy link
Member

@targos targos commented Dec 22, 2017

Commit 1:

tools: move eslint from tools to tools/node_modules

This is required because we need to add the babel-eslint dependency
and it has to be able to resolve "eslint".

Refs: https://github.com/nodejs/node/pull/17755

Commit 2:

tools: add babel-eslint

Create tools/update-babel-eslint.sh script and execute it to do the
first installation of the package.
Update tools/license-builder.sh and execute it to add babel-eslint's
license to our LICENSE file.

Commit 3:

tools: use babel-eslint as ESLint parser
Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • documentation is changed or added
  • commit message follows commit guidelines
Affected core subsystem(s)

tools

/cc @mcollina

@nodejs-github-bot nodejs-github-bot added build Issues and PRs related to build files or the CI. doc Issues and PRs related to the documentations. meta Issues and PRs related to the general management of the project. tools Issues and PRs related to the tools directory. labels Dec 22, 2017
@MylesBorins
Copy link
Contributor

@targos how many files does this create? I'm not going to block, but we should be consistent about decision making on new dependencies

@refack have you had any progress on new ways to vendor deps?

@targos
Copy link
Member Author

targos commented Dec 22, 2017

This creates 1217 files.

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mcollina
Copy link
Member

Commit 2 and 3 could be reverted after AsyncIterators are added to ESlint itself.

@maclover7
Copy link
Contributor

how many files does this create? I'm not going to block, but we should be consistent about decision making on new dependencies

Agree with @MylesBorins's comment. Don't want to start a big bikeshed on this PR, but in theory if this lands, so should #17320, which is very similar in nature.

@Trott
Copy link
Member

Trott commented Dec 22, 2017

Why do we want to add babel-eslint as the parser? (Not objecting, of course, but I do want to understand the motivation!)

@mcollina
Copy link
Member

To support async-iterators. They are curreny a stage 3 proposal, and it’s not supported into eslint yet.

Copy link
Member

@benjamingr benjamingr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rubberstamp lgtm after checking out and seeing things work.

@benjamingr
Copy link
Member

benjamingr commented Dec 24, 2017

@kittens

@cjihrig
Copy link
Contributor

cjihrig commented Dec 24, 2017

According to https://twitter.com/geteslint/status/944829414159810560, there is an issue with babel-eslint and eslint 1.14.0. The issue appears fixed with babel-eslint 8.1.0. Assuming that we'll eventually update to 1.14.0+, it might make sense to update to both of those versions now.

I'm also not big on adding this to the repo, although I won't block this either. Even if we remove them later, they will still be part of the git history.

@targos
Copy link
Member Author

targos commented Dec 24, 2017

I also don't like having to add this dependency, but do we have an alternative?

This will be necessary for import.meta as well.

BTW 1054 of the new files come from lodash :(

@mcollina
Copy link
Member

mcollina commented Jan 2, 2018

I also don't like having to add this dependency, but do we have an alternative?

No, if we want to experiment with the new language feature in node core before they are finalyzed.

Is there anyone objecting landing this?

@gibfahn
Copy link
Member

gibfahn commented Jan 2, 2018

I also don't like having to add this dependency, but do we have an alternative?

Would git submodules work here?

@targos
Copy link
Member Author

targos commented Jan 2, 2018

Added a commit to update ESLint to 4.14.0 and updated babel-eslint to the latest version.

CI: https://ci.nodejs.org/job/node-test-pull-request/12375/

@benjamingr
Copy link
Member

Ping @targos

@mcollina
Copy link
Member

mcollina commented Jan 8, 2018

Are we ok to land this? cc @nodejs/tsc
@targos can you get it rebased?

Copy link
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@targos
Copy link
Member Author

targos commented Jan 9, 2018

It looks like the merge of master is making CI unhappy. Let me rebase this properly.

@targos
Copy link
Member Author

targos commented Jan 9, 2018

Updated

@benjamingr
Copy link
Member

@targos
Copy link
Member Author

targos commented Jan 9, 2018

@benjamingr
Copy link
Member

@targos the older CI I started looks good from what I can tell, everything that is unstable is also unstable on other builds unrelated to the PR.

@targos
Copy link
Member Author

targos commented Jan 9, 2018

@benjamingr Oh, sorry my tab was not up-to-date. I didn't see your message. I stopped my run.

@targos targos reopened this Jan 11, 2018
@targos targos merged commit 4d96c17 into nodejs:master Jan 11, 2018
@targos
Copy link
Member Author

targos commented Jan 11, 2018

Landed in 3dc3063, 7a52c51, b043a70 and 4d96c17.

@targos targos deleted the move-eslint branch January 11, 2018 08:53
@evanlucas
Copy link
Contributor

Does this need to land on v9.x?

evanlucas pushed a commit that referenced this pull request Jan 22, 2018
This is required because we need to add the babel-eslint dependency
and it has to be able to resolve "eslint".
babel-eslint is required to support future ES features such as async
iterators and import.meta.

Refs: #17755
PR-URL: #17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
evanlucas pushed a commit that referenced this pull request Jan 22, 2018
PR-URL: #17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
evanlucas pushed a commit that referenced this pull request Jan 30, 2018
This is required because we need to add the babel-eslint dependency
and it has to be able to resolve "eslint".
babel-eslint is required to support future ES features such as async
iterators and import.meta.

Refs: #17755
PR-URL: #17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
evanlucas pushed a commit that referenced this pull request Jan 30, 2018
PR-URL: #17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
evanlucas pushed a commit that referenced this pull request Jan 30, 2018
Create tools/update-babel-eslint.sh script and execute it to do the
first installation of the package.
Update tools/license-builder.sh and execute it to add babel-eslint's
license to our LICENSE file.

PR-URL: #17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
evanlucas pushed a commit that referenced this pull request Jan 30, 2018
PR-URL: #17820
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
@MylesBorins
Copy link
Contributor

Should we backport this to v6.x or v8.x?

vsemozhetbyt added a commit that referenced this pull request Mar 11, 2018
PR-URL: #19287
Refs: #17820
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
targos pushed a commit that referenced this pull request Mar 17, 2018
PR-URL: #19287
Refs: #17820
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
MylesBorins pushed a commit that referenced this pull request Mar 20, 2018
PR-URL: #19287
Refs: #17820
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
MayaLekova pushed a commit to MayaLekova/node that referenced this pull request May 8, 2018
PR-URL: nodejs#19287
Refs: nodejs#17820
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
@BethGriggs
Copy link
Member

If this gets backported it should come with #19287

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Issues and PRs related to build files or the CI. doc Issues and PRs related to the documentations. meta Issues and PRs related to the general management of the project. tools Issues and PRs related to the tools directory.
Projects
None yet
Development

Successfully merging this pull request may close these issues.