Hello,

tldr: We’re adding JS & Python linting at review phase. See 
https://reviewboard.mozilla.org/r/214622/as example.


A few months ago, we announced automated C/C++ Static Analysis in MozReview 
<https://groups.google.com/forum/#%21topic/mozilla.dev.platform/TFfjCRdGz_E>.As 
the feedback has been very positive, we have been working on bringing the same 
kind of feature for JavaScript and Python.


Thanks to the hard work of Andrew Halberstadt, Mark Banner and others, this 
work has been much easier. Indeed, we are fully relying on outputs provided by 
Mozlint <https://firefox-source-docs.mozilla.org/tools/lint/index.html>. 
JavaScript linting is based on eslint, Python on flake8.


The analysis is performed by our bot the following way:

  *

    Listen to new review requests;

  *

    Apply the patches to a local mozilla-central clone;

  *

    Run the analysis;Here, mach lint will do all the hard work for us.

  *

    Publish the results on Mozreview (or Phabricator)

These actions are usually performed in less than 10 minutes.


We hope this will make the life of reviewers easier and also avoid some 
unnecessary tree breakage because of linter jobs. Also, as long as new linters 
are part of the mach lintinfrastructure, these new verifications will be 
automatically enabled at review phase.


Note that, unlike C/C++ static analysis, Release Management does not manage the 
activation/deactivation of various checkers. This job is done by Andrew and 
Mark, so we will forward any mozlint-related issues to them.


Phabricator support will be enabled in the next few weeks as well.


Please report any issues here: http://bit.ly/2y9N9Vx.


In the future, we are planning to instrument Phabricator to evaluate the 
usefulness of our checkers.


Bastien, Jan & Sylvestre

_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to