mozlint.formatters package

Submodules

mozlint.formatters.stylish module

class mozlint.formatters.stylish.NullTerminal

Bases: object

Replacement for blessings.Terminal() that does no formatting.

class NullCallableString

Bases: unicode

A dummy callable Unicode stolen from blessings

class mozlint.formatters.stylish.StylishFormatter(disable_colors=None)

Bases: object

Formatter based on the eslint default.

fmt = u' {c1}{lineno}{column} {c2}{level}{normal} {message} {c1}{rule}({linter}){normal}'
fmt_summary = u'{t.bold}{c}\u2716 {problem} ({error}, {warning}){t.normal}'

mozlint.formatters.treeherder module

class mozlint.formatters.treeherder.TreeherderFormatter

Bases: object

Formatter for treeherder friendly output.

This formatter looks ugly, but prints output such that treeherder is able to highlight the errors and warnings. This is a stop-gap until bug 1276486 is fixed.

fmt = u'TEST-UNEXPECTED-{level} | {path}:{lineno}{column} | {message} ({rule})'

Module contents

class mozlint.formatters.JSONFormatter

Bases: object

mozlint.formatters.get(name, **fmtargs)