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

INTERNALERROR for no apparent reason #103104

Closed
yurivict opened this issue Mar 29, 2023 · 3 comments
Closed

INTERNALERROR for no apparent reason #103104

yurivict opened this issue Mar 29, 2023 · 3 comments
Labels

Comments

@yurivict
Copy link

yurivict commented Mar 29, 2023

Bug report

Tests fail on the QtPy project like this:

cd /usr/ports/devel/py-QtPy/work-py39/QtPy-2.3.1 && /usr/bin/env XDG_DATA_HOME=/usr/ports/devel/py-QtPy/work-py39  XDG_CONFIG_HOME=/usr/ports/devel/py-QtPy/work-py39  XDG_CACHE_HOME=/usr/ports/devel/py-QtPy/work-py39/.cache  HOME=/usr/ports/devel/py-QtPy/work-py39 PATH=/usr/local/libexec/ccache:/usr/ports/devel/py-QtPy/work-py39/.bin:/home/yuri/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin PKG_CONFIG_LIBDIR=/usr/ports/devel/py-QtPy/work-py39/.pkgconfig:/usr/local/libdata/pkgconfig:/usr/local/share/pkgconfig:/usr/libdata/pkgconfig MK_DEBUG_FILES=no MK_KERNEL_SYMBOLS=no SHELL=/bin/sh NO_LINT=YES PREFIX=/usr/local  LOCALBASE=/usr/local  CC="cc" CFLAGS="-O2 -pipe  -fstack-protector-strong -fno-strict-aliasing "  CPP="cpp" CPPFLAGS=""  LDFLAGS=" -fstack-protector-strong " LIBS=""  CXX="c++" CXXFLAGS="-O2 -pipe -fstack-protector-strong -fno-strict-aliasing  "  MANPREFIX="/usr/local" CCACHE_DIR="/tmp/.ccache" BSD_INSTALL_PROGRAM="install  -s -m 555"  BSD_INSTALL_LIB="install  -s -m 0644"  BSD_INSTALL_SCRIPT="install  -m 555"  BSD_INSTALL_DATA="install  -m 0644"  BSD_INSTALL_MAN="install  -m 444" /usr/local/bin/python3.9 -m pytest -k '' -rs -v -o addopts= 
/usr/local/lib/python3.9/site-packages/pytestqt/logging.py:42: PytestDeprecationWarning: The hookimpl QtLoggingPlugin.pytest_runtest_makereport uses old-style configuration options (marks or attributes).
Please use the pytest.hookimpl(hookwrapper=True) decorator instead
 to configure the hooks.
 See https://docs.pytest.org/en/latest/deprecations.html#configuring-hook-specs-impls-using-markers
  @pytest.mark.hookwrapper
========================================================================================== test session starts ==========================================================================================
platform freebsd13 -- Python 3.9.16, pytest-7.2.1, pluggy-1.0.0 -- /usr/local/bin/python3.9
cachedir: .pytest_cache
hypothesis profile 'default' -> database=DirectoryBasedExampleDatabase('/usr/ports/devel/py-QtPy/work-py39/QtPy-2.3.1/.hypothesis/examples')
Using --randomly-seed=1870392973
PySide2 5.15.2 -- Qt runtime 5.15.8 -- Qt compiled 5.15.8
rootdir: /usr/ports/devel/py-QtPy/work-py39/QtPy-2.3.1, configfile: pytest.ini, testpaths: qtpy/tests
plugins: forked-1.4.0, hypothesis-6.68.2, mypy-plugins-1.10.1, cov-2.9.0, randomly-3.12.0, timeout-2.1.0, rerunfailures-10.1, flaky-3.7.0, xdist-2.5.0, env-0.6.2, freezegun-0.4.2, mock-3.10.0, flake8-1.1.1, typeguard-3.0.2, qt-4.1.0
collected 105 items / 1 skipped                                                                                                                                                                         
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/_pytest/main.py", line 270, in wrap_session
INTERNALERROR>     session.exitstatus = doit(config, session) or 0
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/_pytest/main.py", line 323, in _main
INTERNALERROR>     config.hook.pytest_collection(session=session)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_hooks.py", line 265, in __call__
INTERNALERROR>     return self._hookexec(self.name, self.get_hookimpls(), kwargs, firstresult)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_manager.py", line 80, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_callers.py", line 60, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_result.py", line 60, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_callers.py", line 39, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/_pytest/main.py", line 334, in pytest_collection
INTERNALERROR>     session.perform_collect()
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/_pytest/main.py", line 667, in perform_collect
INTERNALERROR>     hook.pytest_collection_modifyitems(
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_hooks.py", line 265, in __call__
INTERNALERROR>     return self._hookexec(self.name, self.get_hookimpls(), kwargs, firstresult)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_manager.py", line 80, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_callers.py", line 60, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_result.py", line 60, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pluggy/_callers.py", line 39, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pytest_freezegun.py", line 55, in pytest_collection_modifyitems
INTERNALERROR>     if get_closest_marker(item, MARKER_NAME):
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/pytest_freezegun.py", line 17, in get_closest_marker
INTERNALERROR>     if LooseVersion(pytest.__version__) < LooseVersion('3.6.0'):
INTERNALERROR>   File "/usr/local/lib/python3.9/site-packages/setuptools/_distutils/version.py", line 55, in __init__
INTERNALERROR>     warnings.warn(
INTERNALERROR> DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.

========================================================================================== 1 skipped in 1.84s ===========================================================================================
*** Error code 3

Original bug report: spyder-ide/qtpy#418

What triggers the INTERNALERROR message? Is this like Python panic?
How can this be fixed?

Your environment

  • CPython versions tested on: 3.9
  • Operating system and architecture: FreeBSD 13.1
@yurivict yurivict added the type-bug An unexpected behavior, bug, or error label Mar 29, 2023
@JelleZijlstra
Copy link
Member

This error is in pytest, not in the CPython project. Please report it at https://github.com/pytest-dev/pytest.

@JelleZijlstra JelleZijlstra closed this as not planned Won't fix, can't repro, duplicate, stale Mar 29, 2023
@CAM-Gerlach CAM-Gerlach added invalid and removed type-bug An unexpected behavior, bug, or error labels Mar 29, 2023
@CAM-Gerlach
Copy link
Member

For the record, I see that they reported it as pytest-dev/pytest#10846

@CAM-Gerlach
Copy link
Member

It turns out it was actually an error in an unmaintained third-party Pytest plugin (pytest-freezegun) that they happened to have installed in the same environment in which they were running the QtPy test suite, which can be solved by either running the QtPy tests in a clean environment, or uninstalling that plugin and replacing it with its modern maintained replacement, pytest-freezer.

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

No branches or pull requests

3 participants