Uh oh!
There was an error while loading. Please reload this page.
tools: update eslint to v1.x - #2286
Conversation
silverwind
commented
Aug 1, 2015
I don't think we need |
targos
commented
Aug 1, 2015
So we just remove |
silverwind
commented
Aug 1, 2015
Patch doesn't seem to apply cleanly for me:
Did you install the new eslint with |
targos
commented
Aug 1, 2015
I did this: |
silverwind
commented
Aug 1, 2015
Yeah. You could experiment with these options thought: quote-props: [2, "as-needed"]quote-props: [2, "consistent-as-needed"] |
silverwind
commented
Aug 1, 2015
Also, please remove |
targos
commented
Aug 1, 2015
I have one remaining issue with the indent rule and I don't know if it's on our side or eslint's: exec('python -c "print 200000*\'C\'"',{maxBuffer: 1000},function(err,stdout,stderr){assert.ok(err);assert.ok(/maxBuffer/.test(err.message));}); |
targos
commented
Aug 1, 2015
done |
silverwind
commented
Aug 1, 2015
If that's the only case, I'd say refactor to a function expression ( |
silverwind
commented
Aug 1, 2015
You could make that |
silverwind
commented
Aug 1, 2015
Also, I'd suggest doing |
targos
commented
Aug 1, 2015
Isn't it the default behavior ? I don't see dev deps in
I did it like that on last update, thanks for the tip ! |
silverwind
commented
Aug 1, 2015
You're right, I think npm did at some point install devDependencies when that variable wasn't set, but it seems fine now. |
Fishrock123
commented
Aug 1, 2015
targos
commented
Aug 1, 2015
#2205 depends on this. |
Fishrock123
commented
Aug 1, 2015
I'm not sure about the |
targos
commented
Aug 1, 2015
Yes those tests are the only ones with non indented switch cases. (Do not lose too much time reviewing until eslint is fixed upstream) |
56fe182 to
b18a2e9Comparetargos
commented
Aug 8, 2015
Updated to v1.1.0. A bunch of issues have been fixed but there are new ones :( |
silverwind
commented
Aug 8, 2015
Still blocked on eslint/eslint#3173 from what I followed. |
silverwind
commented
Jan 13, 2016
Not too bad, I guess. Eslint is under heavy development after all and they have to take care of a lot of edge cases and ES6 additions. |
silverwind
commented
Jan 13, 2016
@targos two Windows failures, not sure if flaky. The first test was modified here, the second was not: |
silverwind
commented
Jan 13, 2016
Ah, false alarm it looks like. These failures both are present in the previous CI run: https://ci.nodejs.org/job/node-test-binary-windows/577/ Going to land this! |
On case-insensitive platorms, the Debug/ rule catches the debug module under npm and eslint. PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
The no-reserved-keys rule doesn't exist anymore and we don't need ES3 compatibility. escape and unescape are now known by eslint. --reset flag was removed and it is now the default behavior. PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
With an indentation style of two spaces, it is not possible to indent multiline variable declarations by four spaces. Instead, the var keyword is used on every new line. Use const instead of var where applicable for changed lines. PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
Replace var keyword with const or let. PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
jbergstroem
commented
Jan 13, 2016
@silverwind see #4679 |
silverwind
commented
Jan 13, 2016
jbergstroem
commented
Jan 13, 2016
🎉 |
ChALkeR
commented
Jan 14, 2016
Yay! |
On case-insensitive platorms, the Debug/ rule catches the debug module under npm and eslint. PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
PR-URL: #2286 Reviewed-By: Roman Reiss <me@silverwind.io>
thefourtheye
commented
Jan 15, 2016
@targos Great work man :-) |
jasnell
commented
Jan 15, 2016
@rvagg@thealphanerd@targos @nodejs/lts ... I'm struggling on this one to decide if it should go into LTS. If we don't land it, it's likely to make backporting changes more difficult because of the altered linting, but I'm not sure how much of a difference it will make. Any thoughts? |
thefourtheye
commented
Jan 15, 2016
I am inclined to think that this is not an LTS material. Quoting https://github.com/nodejs/LTS#lts-plan,
This doesn't fall under any of the mentioned categories, right? |
jasnell
commented
Jan 15, 2016
@thefourtheye I agree, but as we continue to evolve style rules, it'll make backporting commits a bit more difficult. I can live with it, but @thealphanerd and I could definitely use a bit more active help in getting things pulled back into staging :-) |
thefourtheye
commented
Jan 15, 2016
Ah, right. I didn't think of that. Then +1 to backport this to LTS. |
MylesBorins
commented
Jan 15, 2016
+1 to backporting as well |
silverwind
commented
Jan 15, 2016
Yeah, I think it's necessary too, or else |
rvagg
commented
Jan 16, 2016
I'm +1 on backporting tooling where possible, it makes it easier to manage across branches and it's not really related to API or even the code we're shipping. |
targos
commented
Jan 16, 2016
Proposed backport: #4721 |
This is still a WIP.
I create the PR now because there are several issues to discuss:
no-reserved-keysrule has been removed. It is kind of replaced byquote-propsbut to enable this rule, we need to choose how we want deal with quotes on object properties. Theconsistentoption seems to be the most conservative one if the goal is to limit changes in our code.indentrule changed quite a lot and has now options to control the indentation of specific cases:SwitchCase: I set it to 1, meaning that thecasestatements need 1 level of indent (== 2 spaces) compared to theswitch. There are a few places where we don't follow this rule, like here.VariableDeclarator: I set it to 2. This allows us to align multiple variable declarations withvarorletlike:I haven't pushed the lib and test changes yet because I think there are some problems in eslint with the indent rule. I'll reference this PR when I file the issues.