summaryrefslogtreecommitdiff
path: root/pylintrc
Commit message (Collapse)AuthorAgeFilesLines
* ec: Exclude line-too-long in pylintrcJeremy Bettis2023-05-011-0/+1
| | | | | | | | | | | | | | | | Black doesn't always force lines to wrap at 80 characters. If black formatted it with a long line, then pylint should not complain either. BRANCH=None BUG=None TEST=cros lint util/find_non_exec_lines.py Change-Id: Ie52aa8a5a1102468243ea2602ee0a25e61c9c7ab Signed-off-by: Jeremy Bettis <jbettis@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4496482 Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jeremy Bettis <jbettis@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org>
* ec: Fix cros lint warnings, and add new disablesJeremy Bettis2022-10-181-2/+4
| | | | | | | | | | | | | | | | | | Fix all the cros lint warnings in util/config_option_check.py except for too-many-nested-blocks and too-few-public-methods which are really just opinions and have nothing to do with formatting or potential errors. BRANCH=None BUG=None TEST=cros lint util/config_option_check.py Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I443dd7f8fc4906d7eee979c1a9b666babd4e2ad8 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3957261 Tested-by: Jeremy Bettis <jbettis@chromium.org> Auto-Submit: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Sam Hurst <shurst@google.com> Commit-Queue: Sam Hurst <shurst@google.com>
* Update license boilerplate text in source code filesMike Frysinger2022-09-121-1/+1
| | | | | | | | | | | | | | | Normally we don't do this, but enough changes have accumulated that we're doing a tree-wide one-off update of the name & style. BRANCH=none BUG=chromium:1098010 TEST=`repo upload` works Change-Id: Icd3a1723c20595356af83d190b2c6a9078b3013b Signed-off-by: Mike Frysinger <vapier@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3891203 Reviewed-by: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
* ec: Adjust pylint disabled messagesJeremy Bettis2022-08-171-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | Add several too-many-* disables to the pylintrc file. The very idea that a function can have X of Ys but no more is not helpful. Remove the now duplicated disables from the code. Also, since pylint (at least as called from cros lint) doesn't inherit settings from parent dirs, copy the disables to all child .pylintrc files also. BRANCH=None BUG=None TEST=git ls-files | grep 'py$' | xargs cros lint -v |& less Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I9bb14cd09a066ddd6e2d45cd541cef6695ad36f8 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3833920 Auto-Submit: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Aaron Massey <aaronmassey@google.com> Tested-by: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jack Rosenthal <jrosenth@chromium.org>
* ec: Switch black to 80 cols and reformat filesJeremy Bettis2022-07-261-1/+0
| | | | | | | | | | | | | | | | | | | | Add pyproject.toml config file to set black to 80 columns. Remove column length overrides from other config files. Reformat python files to 80 cols. BRANCH=None BUG=b:238434058 TEST=presubmit/CQ Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I870a68f1bb751f4bad97024045f6e3075489e80f Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3764071 Commit-Queue: Jeremy Bettis <jbettis@chromium.org> Auto-Submit: Jeremy Bettis <jbettis@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
* py: Fix pylint errors discovered by cros lintJeremy Bettis2022-07-141-1/+6
| | | | | | | | | | | | | | | | | | Resolve all pylint warnings in these files. Disable fixme and too-many-arguments globally, because they are very common, and aren't really problems. BRANCH=None BUG=b:238434058 TEST=cros lint Change-Id: I94c410330d6d576d3cc9518503699a514a28758d Signed-off-by: Jeremy Bettis <jbettis@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3760093 Tested-by: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
* ec: Adjust config files for python formattingJeremy Bettis2022-07-081-349/+5
| | | | | | | | | | | | | | | | | | | | | To support formatting all python files with black, isort, and flake8, move some settings from the zmake dir to the root dir. Removed isort from zmake/run_tests.sh, because moving the .isort.cfg confused it, and it needs to be removed anyway. BRANCH=None BUG=b:238434058 TEST=None Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I30d98015a56022ad9f95fdb3b0a7ed6c4bf24094 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3749241 Auto-Submit: Jeremy Bettis <jbettis@chromium.org> Commit-Queue: Jack Rosenthal <jrosenth@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org> Commit-Queue: Jeremy Bettis <jbettis@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org>
* pylintrc: Copy Chromium OS platform2's configCraig Hesling2021-08-021-0/+358
This requests that cros lint (and repo upload hook) use the new Chromium OS 4 space indent policy. Since legacy python scripts still use 2 space, I added pylint ignore statements to the individual files to disable indentation checking. Note: There are still valid pylint errors in some of these legacy scripts. BRANCH=none BUG=none TEST=cros lint util/*.py Signed-off-by: Craig Hesling <hesling@chromium.org> Change-Id: I439f5a87bc50f1f43a4996e574bbc0626922a88e Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3064761 Reviewed-by: Mike Frysinger <vapier@chromium.org> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>