Skip to content

[test] Record and assert thread failures in the overload-reuse test - #96

Open
aaronj0 wants to merge 1 commit into
compiler-research:mainfrom
aaronj0:concurrent-thread-failure-accounting
Open

[test] Record and assert thread failures in the overload-reuse test#96
aaronj0 wants to merge 1 commit into
compiler-research:mainfrom
aaronj0:concurrent-thread-failure-accounting

Conversation

@aaronj0

@aaronj0 aaronj0 commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

As seen on the CI on mac platforms:

[93](https://github.com/compiler-research/cppjit/actions/runs/34221110946/job/102044181415#step:8:702)
    =============================== warnings summary ===============================
    test/test_concurrent.py::TestCONCURRENT::test06_overload_reuse_in_threads
      /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/_pytest/threadexception.py:58: PytestUnhandledThreadExceptionWarning: Exception in thread Thread-104 (test)
      
      Traceback (most recent call last):
        File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/threading.py", line 1075, in _bootstrap_inner
          self.run()
        File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/threading.py", line 1012, in run
          self._target(*self._args, **self._kwargs)
        File "/Users/runner/work/cppjit/cppjit/test/test_concurrent.py", line 257, in test
          simulation.set_something(o, ".")
      TypeError: void CPPOverloadReuse::Simulation1::set_something(std::map<std::string, std::string>, std::string) =>
          TypeError: could not convert argument 1: [InstanceConverter]
      
      Enable tracemalloc to get traceback where the object was allocated.
      See https://docs.pytest.org/en/stable/how-to/capture-warnings.html#resource-warnings for more info.
        warnings.warn(pytest.PytestUnhandledThreadExceptionWarning(msg))

the threads here failed but the test never checked if they raised an exception. This should expose the real failures

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 this pull request may close these issues.

1 participant