Merge pull request #11856 from bluetech/pluggy-unblock
config: use `pluginmanager.unblock` instead of accessing pluggy's internals
This commit is contained in:
commit
ac2cd72e5f
|
@ -64,7 +64,7 @@ repos:
|
||||||
additional_dependencies:
|
additional_dependencies:
|
||||||
- iniconfig>=1.1.0
|
- iniconfig>=1.1.0
|
||||||
- attrs>=19.2.0
|
- attrs>=19.2.0
|
||||||
- pluggy
|
- pluggy>=1.4.0
|
||||||
- packaging
|
- packaging
|
||||||
- tomli
|
- tomli
|
||||||
- types-pkg_resources
|
- types-pkg_resources
|
||||||
|
|
|
@ -46,7 +46,7 @@ py_modules = py
|
||||||
install_requires =
|
install_requires =
|
||||||
iniconfig
|
iniconfig
|
||||||
packaging
|
packaging
|
||||||
pluggy>=1.3.0,<2.0
|
pluggy>=1.4.0,<2.0
|
||||||
colorama;sys_platform=="win32"
|
colorama;sys_platform=="win32"
|
||||||
exceptiongroup>=1.0.0rc8;python_version<"3.11"
|
exceptiongroup>=1.0.0rc8;python_version<"3.11"
|
||||||
tomli>=1.0.0;python_version<"3.11"
|
tomli>=1.0.0;python_version<"3.11"
|
||||||
|
|
|
@ -745,13 +745,10 @@ class PytestPluginManager(PluginManager):
|
||||||
self.set_blocked("pytest_" + name)
|
self.set_blocked("pytest_" + name)
|
||||||
else:
|
else:
|
||||||
name = arg
|
name = arg
|
||||||
# Unblock the plugin. None indicates that it has been blocked.
|
# Unblock the plugin.
|
||||||
# There is no interface with pluggy for this.
|
self.unblock(name)
|
||||||
if self._name2plugin.get(name, -1) is None:
|
|
||||||
del self._name2plugin[name]
|
|
||||||
if not name.startswith("pytest_"):
|
if not name.startswith("pytest_"):
|
||||||
if self._name2plugin.get("pytest_" + name, -1) is None:
|
self.unblock("pytest_" + name)
|
||||||
del self._name2plugin["pytest_" + name]
|
|
||||||
self.import_plugin(arg, consider_entry_points=True)
|
self.import_plugin(arg, consider_entry_points=True)
|
||||||
|
|
||||||
def consider_conftest(
|
def consider_conftest(
|
||||||
|
|
Loading…
Reference in New Issue