File tree Expand file tree Collapse file tree
.agent/skills/python-development Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -176,10 +176,10 @@ Use `--requirements_file=requirements.txt` or custom containers.
176176## Code Quality Tools
177177``` bash
178178# Linting
179- pylint apache_beam/
179+ ruff check apache_beam/
180180
181181# Type checking
182- mypy apache_beam/
182+ pyrefly check apache_beam/
183183
184184# Formatting (via yapf)
185185yapf -i apache_beam/file.py
Original file line number Diff line number Diff line change @@ -31,12 +31,11 @@ repos:
3131 sdks/python/apache_beam/portability/api/.*pb2.*.py
3232 )$
3333
34- - repo : https://github.com/pycqa/pylint
35- # this rev is a release tag in the repo above and corresponds with a pylint
36- # version. make sure this matches the version of pylint in tox.ini.
37- rev : v4.0.2
34+ - repo : https://github.com/astral-sh/ruff-pre-commit
35+ # this rev is a release tag in the repo above and corresponds with a ruff
36+ # version. make sure this matches the version of yapf in setup.py
37+ rev : v0.15.7
3838 hooks :
39- - id : pylint
40- args : ["--rcfile=sdks/python/.pylintrc"]
41- files : ^sdks/python/apache_beam/
42- exclude : *exclude
39+ - id : ruff-check
40+ files : " sdks/python/apache_beam"
41+ args : ["--config=sdks/python/ruff.toml"]
Original file line number Diff line number Diff line change @@ -424,6 +424,12 @@ def get_portability_package_data():
424424 python_requires = python_requires ,
425425 # BEAM-8840: Do NOT use tests_require or setup_requires.
426426 extras_require = {
427+ 'dev' : [
428+ 'isort==7.0.0' ,
429+ 'pyrefly==0.54.0' ,
430+ 'ruff==0.15.7' ,
431+ 'yapf==0.43.0' ,
432+ ],
427433 'dill' : [
428434 # Dill doesn't have forwards-compatibility guarantees within minor
429435 # version. Pickles created with a new version of dill may not
Original file line number Diff line number Diff line change @@ -190,15 +190,12 @@ commands =
190190[testenv:lint]
191191# Don't set TMPDIR to avoid "AF_UNIX path too long" errors in pylint.
192192setenv =
193- # keep the version of pylint in sync with the 'rev' in .pre-commit-config.yaml
194193deps =
195- ruff ==0.15.7
196- isort ==7.0.0
197- pyrefly ==0.54.0
198194 dask ==2022.01.0
199195 distributed ==2022.01.0
200196extras =
201197 gcp
198+ dev
202199commands =
203200 ruff --version
204201 time {toxinidir}/scripts/run_pylint.sh
You can’t perform that action at this time.
0 commit comments