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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add deny list for modules to be skipped on AST generation #2399

Merged
merged 3 commits into from
Mar 25, 2024

Conversation

Jamie-
Copy link
Contributor

@Jamie- Jamie- commented Mar 15, 2024

Type of Changes

Type
✨ New feature

Description

Adds module_denylist to AstroidManager for modules to be skipped during AST generation.
Modules in this list will cause an AstroidImportError to be raised when an AST for them is requested.

Refs pylint-dev/pylint#9442
Used by Pylint PR pylint-dev/pylint#9504

Copy link
Member

@jacobtylerwalls jacobtylerwalls left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wonderful, thank you!

Copy link
Member

@Pierre-Sassoulas Pierre-Sassoulas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great first contribution, just a nit ! The core dump on python 3.10 on pypy is probably unrelated, (but also not flaky, so we need to check on main).

astroid/manager.py Outdated Show resolved Hide resolved
tests/test_manager.py Outdated Show resolved Hide resolved
@Pierre-Sassoulas Pierre-Sassoulas added the Enhancement ✨ Improvement to a component label Mar 18, 2024
@Jamie-
Copy link
Contributor Author

Jamie- commented Mar 20, 2024

Nits fixed :)

@jacobtylerwalls jacobtylerwalls merged commit a2921b3 into pylint-dev:main Mar 25, 2024
18 checks passed
@Jamie- Jamie- deleted the fix-pylint-9442 branch March 25, 2024 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement ✨ Improvement to a component
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants