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

doctestplus failure with pytest 8.1.1 #243

Closed
braingram opened this issue Mar 9, 2024 · 0 comments · Fixed by #242
Closed

doctestplus failure with pytest 8.1.1 #243

braingram opened this issue Mar 9, 2024 · 0 comments · Fixed by #242

Comments

@braingram
Copy link
Contributor

braingram commented Mar 9, 2024

pytest 8.1.1 (just released) contains a consider_namespace_packages argument for import_path. The changes added in #241 use this argument for pytest >=8.2:

if PYTEST_GE_8_2:
consider_namespace_packages = self.config.getini("consider_namespace_packages")
module = import_path(fspath, mode=mode, root=self.config.rootpath,
consider_namespace_packages=consider_namespace_packages)

but unfortunately the above argument change was included in a "bugfix" 8.1.1 version. This produces errors like the following:

.tox/py39-parallel-cov/lib/python3.9/site-packages/pytest_doctestplus/plugin.py:268: in collect
    module = import_path(fspath, mode=mode, root=self.config.rootpath)
E   TypeError: import_path() missing 1 required keyword-only argument: 'consider_namespace_packages'

when running pytest 8.1.1 with pytest-doctestplus 1.2.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant