Personally I think it's would be better to just remove this, since trying with sqlalchemy returned no warning whatsoever, just no collection.
If it was removed we would have at least an attribute error to go by.
See also #9343 (comment)
To reproduce:
git clone https://github.com/sqlalchemy/sqlalchemy.git --depth 100
pip install git+https://github.com/pytest-dev/pytest.git
pytest -Werror
will run and print no tests ran in 13.57s, so the warning seems to not trigger
Originally posted by @CaselIT in #9277 (comment)