Skip to content

pylint sanity test is broken on master #18189

@jtattermusch

Description

@jtattermusch

https://source.cloud.google.com/results/invocations/34141ccf-0fe9-4eba-9412-135e237cdc91/targets/github%2Fgrpc%2Fsanity_linux_dbg_native/tests

It started failing after #18177 - but according to my tests this seems to be a concidence. Perhaps some pylint components were update at the same time and the check is now failing because of that.

++ dirname tools/distrib/pylint_code.sh
+ cd tools/distrib/../..
+ DIRS=('src/python/grpcio/grpc' 'src/python/grpcio_channelz/grpc_channelz' 'src/python/grpcio_health_checking/grpc_health' 'src/python/grpcio_reflection/grpc_reflection' 'src/python/grpcio_testing/grpc_testing' 'src/python/grpcio_status/grpc_status')
+ TEST_DIRS=('src/python/grpcio_tests/tests')
+ VIRTUALENV=python_pylint_venv
+ python3 -m virtualenv python_pylint_venv
Using base prefix '/usr'
New python executable in /var/local/git/grpc/python_pylint_venv/bin/python3
Also creating executable in /var/local/git/grpc/python_pylint_venv/bin/python
Installing setuptools, pip, wheel...
done.
+ PYTHON=python_pylint_venv/bin/python
+ python_pylint_venv/bin/python -m pip install --upgrade pip==18.1
Collecting pip==18.1
  Downloading https://files.pythonhosted.org/packages/c2/d7/90f34cb0d83a6c5631cf71dfe64cc1054598c843a92b400e55675cc2ac37/pip-18.1-py2.py3-none-any.whl (1.3MB)
Installing collected packages: pip
  Found existing installation: pip 19.0.3
    Uninstalling pip-19.0.3:
      Successfully uninstalled pip-19.0.3
Successfully installed pip-18.1
+ python_pylint_venv/bin/python -m pip install --upgrade pylint==2.2.2
Collecting pylint==2.2.2
  Downloading https://files.pythonhosted.org/packages/a5/06/ecef826f319055e6b231716730d7f9047dd7524ffda224b521d989f085b6/pylint-2.2.2-py3-none-any.whl (750kB)
Collecting mccabe (from pylint==2.2.2)
  Downloading https://files.pythonhosted.org/packages/87/89/479dc97e18549e21354893e4ee4ef36db1d237534982482c3681ee6e7b57/mccabe-0.6.1-py2.py3-none-any.whl
Collecting astroid>=2.0.0 (from pylint==2.2.2)
  Downloading https://files.pythonhosted.org/packages/31/e9/610c16ecc417c1918915f8f30e54fcfd195788fe450cf8d7d1a061e14628/astroid-2.2.0-py3-none-any.whl (176kB)
Collecting isort>=4.2.5 (from pylint==2.2.2)
  Downloading https://files.pythonhosted.org/packages/35/c5/025aaa76f0f337e3d91197973c42b4e807fa6dd509da70e87053d85ce278/isort-4.3.9.tar.gz (62kB)
Collecting six (from astroid>=2.0.0->pylint==2.2.2)
  Using cached https://files.pythonhosted.org/packages/73/fb/00a976f728d0d1fecfe898238ce23f502a721c0ac0ecfedb80e0d88c64e9/six-1.12.0-py2.py3-none-any.whl
Collecting wrapt (from astroid>=2.0.0->pylint==2.2.2)
  Downloading https://files.pythonhosted.org/packages/67/b2/0f71ca90b0ade7fad27e3d20327c996c6252a2ffe88f50a95bba7434eda9/wrapt-1.11.1.tar.gz
Collecting typed-ast>=1.3.0; python_version >= "3.7" and implementation_name == "cpython" (from astroid>=2.0.0->pylint==2.2.2)
  Downloading https://files.pythonhosted.org/packages/eb/6a/d6877019d38f5557e286253fc31a5f53a72be9f740ca9617028f4528930a/typed_ast-1.3.1-cp37-cp37m-manylinux1_x86_64.whl (734kB)
Collecting lazy-object-proxy (from astroid>=2.0.0->pylint==2.2.2)
  Downloading https://files.pythonhosted.org/packages/55/08/23c0753599bdec1aec273e322f277c4e875150325f565017f6280549f554/lazy-object-proxy-1.3.1.tar.gz
Building wheels for collected packages: isort, wrapt, lazy-object-proxy
  Running setup.py bdist_wheel for isort: started
  Running setup.py bdist_wheel for isort: finished with status 'done'
  Stored in directory: /root/.cache/pip/wheels/19/26/94/42e70139f9380e2a00ba18f3c4504581139e5d54ac6cec84de
  Running setup.py bdist_wheel for wrapt: started
  Running setup.py bdist_wheel for wrapt: finished with status 'done'
  Stored in directory: /root/.cache/pip/wheels/89/67/41/63cbf0f6ac0a6156588b9587be4db5565f8c6d8ccef98202fc
  Running setup.py bdist_wheel for lazy-object-proxy: started
  Running setup.py bdist_wheel for lazy-object-proxy: finished with status 'done'
  Stored in directory: /root/.cache/pip/wheels/a0/63/e2/6d93295282cb35b53b14b50b602c76dfb04471e21b31d8ad7b
Successfully built isort wrapt lazy-object-proxy
Installing collected packages: mccabe, six, wrapt, typed-ast, lazy-object-proxy, astroid, isort, pylint
Successfully installed astroid-2.2.0 isort-4.3.9 lazy-object-proxy-1.3.1 mccabe-0.6.1 pylint-2.2.2 six-1.12.0 typed-ast-1.3.1 wrapt-1.11.1
You are using pip version 18.1, however version 19.0.3 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
+ EXIT=0
+ for dir in "${DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc -rn src/python/grpcio/grpc
************* Module grpc._interceptor
src/python/grpcio/grpc/_interceptor.py:83:0: R0901: Too many ancestors (8/7) (too-many-ancestors)
src/python/grpcio/grpc/_interceptor.py:129:27: W0613: Unused argument 'callback' (unused-argument)
************* Module grpc._channel
src/python/grpcio/grpc/_channel.py:250:0: R0901: Too many ancestors (8/7) (too-many-ancestors)
-----------------------------------
Your code has been rated at 9.99/10
+ EXIT=1
+ for dir in "${DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc -rn src/python/grpcio_channelz/grpc_channelz
------------------------------------
Your code has been rated at 10.00/10
+ for dir in "${DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc -rn src/python/grpcio_health_checking/grpc_health
------------------------------------
Your code has been rated at 10.00/10
+ for dir in "${DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc -rn src/python/grpcio_reflection/grpc_reflection
------------------------------------
Your code has been rated at 10.00/10
+ for dir in "${DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc -rn src/python/grpcio_testing/grpc_testing
------------------------------------
Your code has been rated at 10.00/10
+ for dir in "${DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc -rn src/python/grpcio_status/grpc_status
------------------------------------
Your code has been rated at 10.00/10
+ for dir in "${TEST_DIRS[@]}"
+ python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc-tests -rn src/python/grpcio_tests/tests
------------------------------------
Your code has been rated at 10.00/10
+ find examples/python -iname '*.py' -not -name '*_pb2.py' -not -name '*_pb2_grpc.py'
+ xargs python_pylint_venv/bin/python -m pylint --rcfile=.pylintrc-examples -rn
------------------------------------
Your code has been rated at 10.00/10
+ exit 1
Command exited with non-zero status 1

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions