Page MenuHomePhabricator

libup should set warnings to off in .eslintrc.json when using maxWarnings: 0
Open, Needs TriagePublic

Description

The Popups extension has maxWarnings: 0 in Gruntfile.js (I am not sure if that is the only wait to set it)

In this case Libup has to set also the warnings (along with errors) in .eslintrc.json to off,

Running "eslint:all" (eslint) task

/src/repo/src/preview/model.js
   9:0  warning  Invalid JSDoc tag (preference). Replace "const" JSDoc tag with "constant"  jsdoc/check-tag-names
  36:0  warning  @extends should not have a bracketed type in "typescript" mode             jsdoc/valid-types
  51:0  warning  @extends should not have a bracketed type in "typescript" mode             jsdoc/valid-types

✖ 3 problems (0 errors, 3 warnings)
  0 errors and 1 warning potentially fixable with the `--fix` option.

Warning: ESLint found too many warnings (maximum: 0) Use --force to continue.

Event Timeline

I think it'd be better to fix the Popups extension being odd.

NearbyPages seems also use this option

I like the idea of having no warnings, because when the warnings does not have effect, nobody looks at them

phpcs also does not allow warnings on CI for php files

NearbyPages seems also use this option

I like the idea of having no warnings, because when the warnings does not have effect, nobody looks at them

phpcs also does not allow warnings on CI for php files

I agree, but that's a discussion for eslint-config-wikimedia.

Change 652278 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[mediawiki/extensions/Popups@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/652278

Change 652279 had a related patch set uploaded (by Legoktm; owner: Legoktm):
[mediawiki/skins/MinervaNeue@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/652279

Change 652279 merged by jenkins-bot:
[mediawiki/skins/MinervaNeue@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/652279

Change 652278 merged by jenkins-bot:
[mediawiki/extensions/Popups@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/652278

Change 652466 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/tools/api-testing@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/652466

Change 652466 merged by jenkins-bot:
[mediawiki/tools/api-testing@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/652466

Change 653457 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/change-propagation@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653457

Change 653458 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/eventstreams@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653458

Change 653459 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/graphoid@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653459

Change 653460 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/mathoid@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653460

Change 653461 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/recommendation-api@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653461

Change 653462 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/restbase@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653462

Change 653463 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/services/wikifeeds@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653463

max warnings 0 --> error = warning this did never made sense to me:-)
As it has been merged for Popups, I'll also merge this for mathoid. On the other side, I think the discussion here might have been too sloppy not investigating in detail which warnings are severe enough to convert them to errors... However, I don't want to play the devil's advocate here.

Change 653463 merged by jenkins-bot:
[mediawiki/services/wikifeeds@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653463

Change 653461 merged by jenkins-bot:
[mediawiki/services/recommendation-api@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653461

Change 653458 merged by jenkins-bot:
[mediawiki/services/eventstreams@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653458

Change 653457 merged by jenkins-bot:
[mediawiki/services/change-propagation@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653457

Change 653460 merged by jenkins-bot:
[mediawiki/services/mathoid@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653460

Change 653783 had a related patch set uploaded (by Mainframe98; owner: Mainframe98):
[mediawiki/skins/Mirage@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653783

Change 653783 merged by jenkins-bot:
[mediawiki/skins/Mirage@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/653783

Change 660319 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/extensions/NearbyPages@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/660319

Change 653459 abandoned by Umherirrender:
[mediawiki/services/graphoid@master] build: Remove maxWarnings: 0 from eslint configuration

Reason:

https://gerrit.wikimedia.org/r/653459

Change 653462 abandoned by Umherirrender:
[mediawiki/services/restbase@master] build: Remove maxWarnings: 0 from eslint configuration

Reason:

https://gerrit.wikimedia.org/r/653462

Change 660319 merged by jenkins-bot:
[mediawiki/extensions/NearbyPages@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/660319

Change 661985 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/skins/Vector@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/661985

Change 661985 merged by jenkins-bot:
[mediawiki/skins/Vector@master] build: Remove maxWarnings: 0 from eslint configuration

https://gerrit.wikimedia.org/r/661985