How to disable Missing class docstring in git hub actions .yml file

Viewed 21

I have one .yml file

name: Pylint

on: [push]

jobs:
  build:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: ["3.8", "3.9", "3.10"]
    steps:
    - uses: actions/checkout@v3
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v3
      with:
        python-version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install pylint Django numpy SQLAlchemy sqlparse
        pip install pylint
    - name: Analysing the code with pylint
      run: |
        pylint $(git ls-files '*.py')

in this i want to add disable command of C0115: Missing class docstring of pylint.

2 Answers

From the Pylint FAQ:

With Pylint < 0.25, add

pylint: disable-all

at the beginning of the module.

Pylint 0.26.1 and up have renamed that directive to

pylint: skip-file

(but the first version will be kept for backward compatibility).

In order to ease finding which modules are ignored a information-level message I0013 is emitted. With recent versions of Pylint, if you use the old syntax, an additional I0014 message is emitted.

You can create a configuration file for that:

In an ini file (pylintrc/setup.cfg/.pylintrc):

disable =
    missing-class-docstring,

Or in a pyproject.toml:

[tool.pylint.main]
disable = ["missing-class-docstring"]
Related