-
-
Couldn't load subscription status.
- Fork 2.9k
Add option to disable plugin auto-loading #3787
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good initial iteration
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a minor thing, don't block on my review / approval 👍
src/_pytest/config/__init__.py
Outdated
|
|
||
| self.pluginmanager.rewrite_hook = hook | ||
|
|
||
| if os.environ.get("PYTEST_DISABLE_PLUGIN_AUTOLOAD", ""): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the default value can be left out here since get() returns None by default
If `PYTEST_DISABLE_PLUGIN_AUTOLOAD` is set, disable auto-loading of plugins through setuptools entrypoints. Only plugins that have been explicitly specified are loaded. ref #3784.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well done @hsoft, thanks!
|
Invited @hsoft to join |
If
PYTEST_DISABLE_PLUGIN_AUTOLOADis set, disable auto-loading ofplugins through setuptools entrypoints. Only plugins that have been
explicitly specified are loaded.
ref #3784.