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 fails with pytest==8.1.0 #239

Closed
hagenw opened this issue Mar 4, 2024 · 4 comments
Closed

doctestplus fails with pytest==8.1.0 #239

hagenw opened this issue Mar 4, 2024 · 4 comments
Assignees

Comments

@hagenw
Copy link

hagenw commented Mar 4, 2024

pytest v8.1.0 was released a few days ago, and with that new version our unit tests fail with:

INTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/_pytest/main.py", line 280, in wrap_session
INTERNALERROR>     config._do_configure()
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/_pytest/config/__init__.py", line 1119, in _do_configure
INTERNALERROR>     self.hook.pytest_configure.call_historic(kwargs=dict(config=self))
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pluggy/_hooks.py", line 523, in call_historic
INTERNALERROR>     res = self._hookexec(self.name, self._hookimpls.copy(), kwargs, False)
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pluggy/_manager.py", line 119, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pluggy/_callers.py", line 138, in _multicall
INTERNALERROR>     raise exception.with_traceback(exception.__traceback__)
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pluggy/_callers.py", line 102, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pytest_doctestplus/plugin.py", line 510, in pytest_configure
INTERNALERROR>     config.pluginmanager.register(
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/_pytest/config/__init__.py", line 497, in register
INTERNALERROR>     plugin_name = super().register(plugin, name)
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pluggy/_manager.py", line 167, in register
INTERNALERROR>     self._verify_hook(hook, hookimpl)
INTERNALERROR>   File "/opt/hostedtoolcache/Python/3.10.13/x64/lib/python3.10/site-packages/pluggy/_manager.py", line 342, in _verify_hook
INTERNALERROR>     raise PluginValidationError(
INTERNALERROR> pluggy._manager.PluginValidationError: Plugin 'doctestplus' for hook 'pytest_collect_file'
INTERNALERROR> hookimpl definition: pytest_collect_file(path, parent)
INTERNALERROR> Argument(s) {'path'} are declared in the hookimpl but can not be found in the hookspec

see https://github.com/audeering/audbackend/actions/runs/8138487619/job/22239475750?pr=190

@effigies
Copy link
Contributor

effigies commented Mar 4, 2024

It looks like this was fixed in #236, but the fix hasn't been released.

@hagenw
Copy link
Author

hagenw commented Mar 4, 2024

Oh sorry, I just searched for a related issue, not related pull request ;)

For a user it would be nice to have a release soon then.

@pllim
Copy link
Contributor

pllim commented Mar 4, 2024

I can make a release.

@pllim pllim self-assigned this Mar 4, 2024
@pllim
Copy link
Contributor

pllim commented Mar 4, 2024

pytest-doctestplus 1.2.0 is released.

But then again pytest 8.1 was also yanked. 🤷

@pllim pllim closed this as completed Mar 4, 2024
clrpackages pushed a commit to clearlinux-pkgs/pypi-nibabel that referenced this issue Oct 15, 2024
…ion 5.3.0

Brendan Moloney (12):
      ENH: Add writer for Siemens CSA header
      CLN: Cleanup whitespace and formatting
      BF: Fix for 'split' (concatenated?) multiframe DICOM
      BF+TST: Test and fix a bunch of multiframe fixes
      BF: Trim unneeded trailing indices from _frame_indices
      BF+TST: Fix 2D plus time case
      BF+TST: Handle case with extra-spatial index that is unique per frame
      TST: Expand test coverage for multiframe dicom shape determination
      TST+CLN: More slice ordering testing, minor cleanup
      DOC: Add some notes to the changelog
      BF+ENH: Fixes to DICOM scaling, make frame filtering explicit
      TST: Don't assume pydicom installed in test_dicomwrappers

Christopher J. Markiewicz (72):
      ENH: Catch SVD failure and raise informative HeaderDataError
      DOC: Fix references in changelog
      MNT: Add tool for generating GitHub-friendly release notes
      MNT: Avoid isort version with broken extras
      DOC: Fix intersphinx mapping and reference type
      MNT: Advertise Python 3.12 support
      FIX: Tolerate missing git
      MNT: Purge defunct nisext package
      TEST: Accommodate pytest 8 changes
      TYP: Update ignore comments
      TEST: Prepare tests to fail at 6.0
      DATA: Add dcm_qa_xa30 as submodule for test data
      TEST: Add test for Siemens TRACE volume
      FIX: Conditionally drop isotropic frames
      RF: Consistently apply data type, shape and index order in GIFTI data blocks
      TEST: Expect data arrays to be the advertised shapes
      CI: Configure dependabot to update official actions in bulk
      Update .github/workflows/test.yml
      Update .github/workflows/test.yml
      STY: blue/flake8
      PIN: Temporarily pin pytest<8.1, pending scientific-python/pytest-doctestplus#239
      FIX: Use np.asarray instead of np.array(..., copy=False)
      Update doc/README.rst
      TOX: Update dependencies for arm64
      CI: Add/distinguish macos-13-x64 and macos-14-arm64 runs
      TOX: Print durations to see slow tests
      CI: Run pre-release tests only on SPEC-0 supported Python
      MNT: Fix ruff arg in pre-commit config
      ENH: Add Nifti2 capabilities to nib-nifti-dx
      MNT: Update importlib_resources requirement to match 3.12 usage
      FIX: Use legacy numpy printing during doc builds/tests
      MNT: Update coverage config
      MNT: Remove "pragma: no cover" from lines ignored by config
      MNT: Require coverage>=7.2 for exclude_also
      MNT: Stop excluding tests from coverage
      CI: Add 3.13-nogil build
      TOX: Add a Python 3.13 environment
      TOX: Drop h5py and indexed_gzip dependencies for dev
      CI: Run tox in debug to see what files are downloaded
      TOX: Add PYTHON_GIL=0 to py313 environments
      RF: Replace OneTimeProperty/auto_attr with cached_property
      DOC: Use packaging.version.Version over LooseVersion
      RF: nibabel.onetime.auto_attr -> functools.cached_property
      fix: Update order of indices on mouseclick
      test: Add regression test for rotated data
      Revert "ENH: Add writer for Siemens CSA header"
      TYP: Ignore overzealous warning for min/max with numpy scalars
      Update pre-commit config
      typ: Ignore Pointset.__rmatmul__/ndarray.__matmul__ inconsistency
      MNT: Require typing_extensions for Python <3.13
      RF: Add generic NiftiExtension base class
      ENH: Add .text and .json() accessors for ease
      TEST: Test content, text and json() access
      ENH: Add from_bytes method for subclasses with known codes
      TYP: Annotate Cifti2Extension
      rf: Allow extensions to be constructed from objects without serialization
      rf: Construct DicomExtensions more simply
      TEST: Test NiftiJSONExtension
      feat: Add current extension codes
      Update nibabel/nifti1.py
      fix: Import from typing in Python 3.13
      Update nibabel/nifti1.py
      sty: Remove unnecessary trailing whitespace in summary
      sty: Apply UP007, UP012
      DOC: Update changelog
      DOC: Update Zenodo contributors
      DOC: Update mailmap and contributor list
      DOC: Remove end year from copyright
      MNT: Update support matrix for Python and numpy
      MNT: Remove workarounds used for Python 3.8 support
      STY: ruff check --fix
      MNT: Update release notes translator

Dimitri Papadopoulos Orfanos (93):
      MNT: Apply Repo-Review suggestions
      MNT: blue/isort/flake8 → ruff
      MNT: run `ruff --fix` and `ruf format`
      MNT: ruff 0.1.9 → 0.3.0
      MNT: run `ruff check --fix` and `ruff format`
      MNT: get rid of .flake8/.pep8speaks.yml
      MNT: ignore F401 in __init__.py
      MNT: ruff 0.3.0 → 0.3.4
      Update doc/tools/apigen.py
      Update nibabel/cifti2/tests/test_cifti2io_header.py
      Update nibabel/gifti/tests/test_gifti.py
      Update nibabel/tests/test_pkg_info.py
      Update nibabel/gifti/tests/test_gifti.py
      Update nibabel/tests/test_spatialimages.py
      Update nibabel/tests/test_testing.py
      Update tox.ini
      Update nibabel/tests/test_testing.py
      Update nibabel/gifti/tests/test_gifti.py
      Update nibabel/gifti/tests/test_gifti.py
      Update nibabel/gifti/tests/test_parse_gifti_fast.py
      Update nibabel/gifti/tests/test_parse_gifti_fast.py
      Update nibabel/nicom/tests/test_dicomwrappers.py
      Update nibabel/streamlines/tests/test_tck.py
      Update nibabel/streamlines/tests/test_trk.py
      Update nibabel/tests/test_affines.py
      Update nibabel/tests/test_arraywriters.py
      Update nibabel/tests/test_arraywriters.py
      Update nibabel/tests/test_image_load_save.py
      Update nibabel/tests/test_imageclasses.py
      Update nibabel/tests/test_minc2.py
      Put back argument, used by @pytest.fixture
      MNT: ignore F401 in doc/source/conf.py
      MNT: Get rid of last `coding: utf-8`
      STY: Apply ruff/flake8-implicit-str-concat rule ISC001
      STY: Applty ruff/pyupgrade rule UP006
      STY: Apply ruff/pyupgrade rule UP031
      STY: Apply ruff/pyupgrade rule UP032
      STY: Enforce ruff/pyupgrade rules (UP)
      STY: Apply ruff/Pylint rule PLE0101
      STY: Enforce ruff/Pylint rules, errors only (PLE)
      STY: Apply ruff/flake8-raise rule RSE102
      STY: Enforce ruff/flake8-raise rules (RSE)
      STY: Apply ruff/flake8-bugbear rule B009
      STY: Apply ruff/flake8-bugbear rule B015
      STY: Enforce ruff/flake8-bugbear rules (B)
      STY: Apply ruff/flake8-comprehensions rule C406
      STY: Apply ruff/flake8-comprehensions rule C413
      STY: Apply ruff/flake8-comprehensions rule C416
      STY: Apply ruff/flake8-comprehensions rule C419
      STY: Enforce ruff/flake8-comprehensions rules (C4)
      STY: Apply ruff/flake8-type-checking rule TCH001
      STY: Apply ruff/flake8-type-checking rule TCH002
      STY: Apply ruff/flake8-type-checking rule TCH003
      STY: Enforce ruff/flake8-type-checking rules (TCH)
      STY: Apply ruff/flake8-pie rule PIE807
      STY: Apply ruff/flake8-pie rule PIE808
      STY: Enforce ruff/flake8-pie rules (PIE)
      STY: Apply ruff/refurb rule FURB167
      STY: Enforce ruff/refurb rules (FURB)
      STY: Apply ruff/flake8-pyi rule PYI034
      STY: Enforce ruff/flake8-pyi rules (PYI)
      STY: Apply ruff/flynt rule FLY002
      STY: Enforce ruff/flynt rules (FLY)
      STY: Apply ruff/Perflint rule PERF102
      STY: Apply ruff/Perflint rule PERF401
      STY: Enforce ruff/Perflint rules (PERF)
      STY: Consistency
      STY: Prefix unused loop control variable with an underscore
      STY: Apply ruff/flake8-pytest-style rule PT006
      STY: Apply ruff/flake8-pytest-style rule PT014
      STY: Apply ruff/flake8-pytest-style rule PT015
      STY: Apply ruff/flake8-pytest-style rule PT017
      STY: Apply ruff/flake8-pytest-style rule PT022
      STY: Apply ruff/flake8-pytest-style rule PT027
      STY: Enforce ruff/flake8-pytest-style rules (PT)
      MNT: Drop test which verifies that TripWireError is an AttributeError
      MNT: Simplify try/except/else block
      STY: Apply ruff/pygrep-hooks rule PGH004
      STY: Apply ruff/pygrep-hooks rule PGH004
      STY: Enforce ruff/pygrep-hooks rules (PGH)
      STY: Apply ruff rule RUF100
      STY: Encorce ruff rules (RUF)
      STY: Disable deprecated ruff rules
      STY: Apply ruff/pyupgrade preview rule UP031
      MNT: Python 3 string formatting: %i → %d
      STY: Apply ruff/refurb preview rule FURB145
      STY: Apply ruff/refurb preview rule FURB148
      STY: Apply ruff/refurb preview rule FURB157
      STY: Apply ruff/refurb preview rule FURB192
      STY: Apply ruff/flake8-comprehensions preview rule C409
      STY: Apply ruff/flake8-comprehensions preview rule C419
      MNT: Fix misspellings found by codespell
      MNT: better way to normalize sequences to lists and flatten

Guillaume Becq (5):
      Update OrthoSlicer3D._set_position in viewers.py
      Add files via upload
      Add files via upload
      BF for non RAS matrices
      test for BF viwers non RSA matrices

Jon Haitz Legarreta (7):
      DOC: Update affiliation of jhlegarreta
      RF: Prefer using `getlocale()` instead of `getdefaultlocale()`
      RF: Prefer using `np.vstack` instead of `np.row_stack`
      RF: Fix `ast` library type and attribute deprecation warnings
      RF: Remove unnecessary call to `asbytes` for `b`-prepended strings
      RF: Fix for `abc` library `Traversable` class module
      RF: Use `numpy.lib.scimath` to demonstrate warning context manager

Joshua Newton (3):
      `casting.py`: Filter WSL1 + np.longdouble warning
      `casting.py`: Remove `uname` check for WSL1
      `.zenodo.json`: Add Joshua Newton

Matthew Brett (1):
      DOC: fix typos for key

Paul McCarthy (2):
      TEST: Unit test for loading ASCII-encoded "flat" GIFTI data array. Currently failing
      RF: Make sure that ASCII-encoded DataArrays are returned with expected shape

Sandro (3):
      Python 3.13: Account for dedented docstrings
      Update instructions for building docs
      Replace deprecated setup() and teardown()

Serge Koudoro (1):
      allow inhomogeneous array

Yaroslav O. Halchenko (1):
      Make "Calculated shape" more "correct" (do show shape) and informative

dependabot[bot] (3):
      Build(deps): Bump the actions-infrastructure group with 3 updates
      Build(deps): Bump codecov/codecov-action from 3 to 4
      Bump deadsnakes/action from 3.1.0 to 3.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

No branches or pull requests

3 participants