We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hi,
When I run the following test:
import pytest_check as check from concurrent.futures.thread import ThreadPoolExecutor def force_fail(): check.equal(1 + 1, 3, "Is 1+1 equal to 3?") def test_thread(): with ThreadPoolExecutor() as executor: task = executor.submit(force_fail) task.result()
pytest-check fails with the following:
venv/lib/python3.11/site-packages/pytest_check/pseudo_traceback.py:35: in _build_pseudo_trace_str (file, line, func, context) = get_full_context(level) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ level = 10 def get_full_context(level): > (_, filename, line, funcname, contextlist) = inspect.stack()[level][0:5] E IndexError: list index out of range
The above is with python3.11 on macOS, but I've seen the same error on our Linux executors.
I am running:
$ pip freeze iniconfig==2.0.0 packaging==23.1 pluggy==1.0.0 pytest==7.3.1 pytest-check==2.1.4 $ python --version Python 3.11.3
The text was updated successfully, but these errors were encountered:
Fix traceback construction in tests using threadpool
4d55b00
Issue okken#127
merged and released as version 2.1.5
Sorry, something went wrong.
py-test-check: updated to 2.1.5
8e7a96f
2.1.5 Fixed - Fix [127](okken/pytest-check#127) IndexError when running a check in a thread
No branches or pull requests
Hi,
When I run the following test:
pytest-check fails with the following:
The above is with python3.11 on macOS, but I've seen the same error on our Linux executors.
I am running:
The text was updated successfully, but these errors were encountered: