Project

General

Profile

Actions

Bug #21448

closed

npm lint fails when plugin has additional dependencies

Added by Tomáš Strachota over 6 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Category:
JavaScript stack
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

The lint script in the foreman just includes files from plugins into a lint run executed from the context of the foreman. This causes troubles when a plugin adds some custom lint dependency (like eslint-plugin-jest from the example below).

[foreman|2.4.1|develop] npm run lint

> TheForemanDevDeps@1.17.0 lint /home/vagrant/foreman/foreman
> eslint -c .eslintrc webpack/ script/ $(./script/foreman_plugins_eslint.js) || exit 0

Oops! Something went wrong! :(

ESLint couldn't find the plugin "eslint-plugin-jest". This can happen for a couple different reasons:

1. If ESLint is installed globally, then make sure eslint-plugin-jest is also installed globally. A globally-installed ESLint cannot find a locally-installed plugin.

2. If ESLint is installed locally, then it's likely that the plugin isn't installed correctly. Try reinstalling by running the following:

    npm i eslint-plugin-jest@latest --save-dev

If you still can't figure out the problem, please stop by https://gitter.im/eslint/eslint to chat with the team.

Actions #1

Updated by The Foreman Bot over 6 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/4946 added
Actions #2

Updated by Walden Raines over 6 years ago

  • Target version changed from 224 to 228
Actions #3

Updated by Daniel Lobato Garcia over 6 years ago

  • translation missing: en.field_release set to 296
Actions #4

Updated by Anonymous over 6 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF