Page MenuHomePhabricator

ESLint build fails on the CI because of 'mediawiki/docs'
Closed, ResolvedPublic

Description

I made a fresh pull from the master before pushing my patch to gerrit and it caused the ESLint build to fail with the following error:

/Users/soham/Desktop/mediawiki/resources/src/mediawiki.action/mediawiki.action.edit.preview.js
  215:7  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

/Users/soham/Desktop/mediawiki/resources/src/mediawiki.notification/notification.js
  43:5  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

/Users/soham/Desktop/mediawiki/resources/src/mediawiki.rcfilters/ui/ChangesListWrapperWidget.js
  142:4  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

/Users/soham/Desktop/mediawiki/resources/src/mediawiki.rcfilters/ui/FilterMenuSectionOptionWidget.js
  94:2  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

/Users/soham/Desktop/mediawiki/resources/src/mediawiki.rcfilters/ui/ItemMenuOptionWidget.js
  137:3  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

/Users/soham/Desktop/mediawiki/resources/src/mediawiki.rcfilters/ui/SavedLinksListItemWidget.js
  105:2  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

/Users/soham/Desktop/mediawiki/tests/phpunit/data/resourceloader/vue-component.vue
  1:1  error  Parsing error: Unexpected token <

/Users/soham/Desktop/mediawiki/tests/qunit/suites/resources/mediawiki/mediawiki.loader.test.js
  62:4  error  Definition for rule 'mediawiki/class-doc' was not found  mediawiki/class-doc

✖ 16 problems (8 errors, 8 warnings)

To replicate:

  1. Follow the steps to clone mediawiki/core repo using gerrit
  2. Run npx grunt eslint

OS Version: OSX Mojave
NodeJS Version: 12.x

Event Timeline

Soham created this task.Apr 21 2020, 2:55 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptApr 21 2020, 2:55 PM
Soham updated the task description. (Show Details)Apr 21 2020, 2:55 PM
zeljkofilipin triaged this task as Medium priority.
zeljkofilipin moved this task from Backlog 🔙 to In Progress 🔨 on the User-zeljkofilipin board.

There was a version update to suppport .vue (which is also failing in your list)

https://gerrit.wikimedia.org/r/#/c/mediawiki/core/+/584781/4/package.json

Have you run npm update or npm ci to get in the last version updates?

Soham added a comment.Apr 21 2020, 8:01 PM

I have run npm ci to set up mediawiki after getting a fresh pull from master. However let me try that again.

Soham added a comment.Apr 21 2020, 9:01 PM
This comment was removed by Soham.
Soham closed this task as Resolved.Apr 21 2020, 9:02 PM
Soham reopened this task as Open.
Soham added a comment.Apr 21 2020, 9:04 PM

@Umherirrender neither worked for me

It works for me with. Maybe use npm install or npm rebuild to get a fresh installation

Soham added a comment.EditedMay 10 2020, 5:45 AM

This error was automatically resolved after I worked on a merge conflict. Turns out the package.json file in my local copy of Mediawiki/core was using a lower version of grunt. I rebased my local copy of code with mediawiki/core master and this resolved the issue

Soham closed this task as Resolved.May 10 2020, 5:46 AM