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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Pylint #90827

Open
yuval-gvs opened this issue Dec 14, 2022 · 0 comments
Open

Support for Pylint #90827

yuval-gvs opened this issue Dec 14, 2022 · 0 comments
Labels
module: lint Issues related to our Python/C++ lint rules (run by Travis) triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Comments

@yuval-gvs
Copy link

馃殌 The feature, motivation and pitch

Using linters is crucial for code safety and clarity. One of the commonly used linters Pylint (e.g. default for Visual Studio Code), fails to find members in the torch module as these are supposedly generated (see pylint-dev/pylint#7937).

Alternatives

Pylint supports external C libraries through the use of the --extension-pkg-allow-list option, and this works well e.g. for NumPy, but not for PyTorch.
The common solution people use is to completely ignore torch members by using --generated-members=numpy.*,torch.*, which is like using no linting for PyTorch at all.

Additional context

This issue has been repeatedly brought up with no solution, see #24807, #1942, #701. PyLint devs claim they are unable to receive member information from PyTorch, see pylint-dev/pylint#7937.

@albanD albanD added module: lint Issues related to our Python/C++ lint rules (run by Travis) triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module labels Mar 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module: lint Issues related to our Python/C++ lint rules (run by Travis) triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module
Projects
None yet
Development

No branches or pull requests

2 participants