Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replaces pylint with ruff #7438

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
17 changes: 1 addition & 16 deletions .bbtravis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,8 @@ env:
matrix:
fast_finish: true
include:
# flake8, isort, pylint, docs first as they're more likely to find issues
- env: PYTHON=3.9 TWISTED=latest SQLALCHEMY=latest TESTS=flake8
# ruff, docs first as they're more likely to find issues
- env: PYTHON=3.9 TWISTED=latest SQLALCHEMY=latest TESTS=ruff
- env: PYTHON=3.9 TWISTED=latest SQLALCHEMY=latest TESTS=pylint NUM_CPU=2 MEMORY_SIZE=2G
- env: PYTHON=3.9 TWISTED=latest SQLALCHEMY=latest TESTS=docs

# add js tests in separate job. Start it early because it is quite long
Expand Down Expand Up @@ -168,19 +166,6 @@ script:
condition: TESTS == "ci/coverage"
cmd: /tmp/bbvenv/bin/coverage run --rcfile=.coveragerc /tmp/bbvenv/bin/trial -j8 --reporter=text --rterrors buildbot.test buildbot_worker.test

# Run additional tests in their separate job
- title: pylint
condition: TESTS == "pylint"
cmd: |
export PATH=/tmp/bbvenv/bin/:$PATH
make pylint

- title: flake8
condition: TESTS == "flake8"
cmd: |
export PATH=/tmp/bbvenv/bin/:$PATH
make flake8

- title: ruff
condition: TESTS == "ruff"
cmd: |
Expand Down
16 changes: 1 addition & 15 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
DOCKERBUILD := docker build --build-arg http_proxy=$$http_proxy --build-arg https_proxy=$$https_proxy
ROOT_DIR := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST))))

.PHONY: docs pylint flake8 virtualenv
.PHONY: docs ruff virtualenv


VENV_NAME := .venv$(VENV_PY_VERSION)
Expand Down Expand Up @@ -51,20 +51,6 @@ docs-release: docs-towncrier
docs-release-spelling: docs-towncrier
$(MAKE) -C master/docs SPHINXOPTS=-W spelling

# pylint the whole sourcecode (validate.sh will do that as well, but only process the modified files)
pylint:
$(MAKE) -C master pylint; master_res=$$?; \
$(MAKE) -C worker pylint; worker_res=$$?; \
if [ $$master_res != 0 ] || [ $$worker_res != 0 ]; then exit 1; fi

# flake8 the whole sourcecode (validate.sh will do that as well, but only process the modified files)
flake8:
$(MAKE) -C master flake8
$(MAKE) -C worker flake8
flake8 --config=common/flake8rc www/*/buildbot_*/
flake8 --config=common/flake8rc www/*/setup.py
flake8 --config=common/flake8rc common/*.py

frontend_deps: $(VENV_NAME)
$(PIP) install -e pkg
$(PIP) install build wheel buildbot
Expand Down