diff --git a/changelog/9636.bugfix.rst b/changelog/9636.bugfix.rst new file mode 100644 index 00000000000..2288c37ffc7 --- /dev/null +++ b/changelog/9636.bugfix.rst @@ -0,0 +1 @@ +The ``pythonpath`` plugin was renamed to ``python_path``. This avoids a conflict with the ``pytest-pythonpath`` plugin. diff --git a/src/_pytest/config/__init__.py b/src/_pytest/config/__init__.py index 59c88885df5..f4818c861cf 100644 --- a/src/_pytest/config/__init__.py +++ b/src/_pytest/config/__init__.py @@ -254,7 +254,7 @@ def directory_arg(path: str, optname: str) -> str: "warnings", "logging", "reports", - "pythonpath", + "python_path", *(["unraisableexception", "threadexception"] if sys.version_info >= (3, 8) else []), "faulthandler", ) diff --git a/src/_pytest/pythonpath.py b/src/_pytest/python_path.py similarity index 100% rename from src/_pytest/pythonpath.py rename to src/_pytest/python_path.py diff --git a/testing/test_config.py b/testing/test_config.py index bf4b2741eca..8013966f071 100644 --- a/testing/test_config.py +++ b/testing/test_config.py @@ -1275,7 +1275,7 @@ def pytest_load_initial_conftests(self): ("_pytest.config", "nonwrapper"), (m.__module__, "nonwrapper"), ("_pytest.legacypath", "nonwrapper"), - ("_pytest.pythonpath", "nonwrapper"), + ("_pytest.python_path", "nonwrapper"), ("_pytest.capture", "wrapper"), ("_pytest.warnings", "wrapper"), ] diff --git a/testing/test_pythonpath.py b/testing/test_python_path.py similarity index 98% rename from testing/test_pythonpath.py rename to testing/test_python_path.py index 97c439ce0c3..5ee0f55e36a 100644 --- a/testing/test_pythonpath.py +++ b/testing/test_python_path.py @@ -81,7 +81,7 @@ def test_no_ini(pytester: Pytester, file_structure) -> None: def test_clean_up(pytester: Pytester) -> None: - """Test that the pythonpath plugin cleans up after itself.""" + """Test that the plugin cleans up after itself.""" # This is tough to test behaviorly because the cleanup really runs last. # So the test make several implementation assumptions: # - Cleanup is done in pytest_unconfigure().