google / google/sbsim

Enable contributors to check for Google-specific Pylint Errors

Open
#40 0 comments 0 reactions 1 assignee Claimed by @s2t2 View on GitHub
Dominant language
Python
Stars
123
Forks
56
Avg merge
17d 18h
Merged PRs (30d)
3

Description

We can use open source tools to check for generic `pylint` errors:

```sh
# example of checking for a generic error (e.g. C0114):
pylint smart_control --ignore=proto --disable=all --enable=C0114
```

However these methods don't work with Google-specific errors (i.e. messages beginning with "g-").

These Google-specific errors and corresponding codes are listed in internal company documentation about the `gpylint` tool, but both the documentation and the `gpylint` tool itself are not available to open source contributors.

We should try to allow open source contributors (and automated GitHub Actions workflows) to somehow check for these Google-specific errors as well. Otherwise there are likely to be frequent linting and formatting changes that happen during the Copybara sync process when we are merging code back into the Google codebase.

It may be helpful to see how other open source libraries like Tensorflow are handling this. Here is a link to the [Tensorflow "pylintrc" file](https://github.com/tensorflow/tensorflow/blob/master/tensorflow/tools/ci_build/pylintrc), which may contain some answers.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.