pybind / pybind/pybind11

[BUG]: Test test_cross_module_exception_translator fails

Open
#3,537 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

triage
Dominant language
C++
Stars
18k
Forks
2.3k
Avg merge
5d 17h
Merged PRs (30d)
10

Description

Required prerequisites
Problem description
_________________________________________________________________________ test_cross_module_exception_translator ___________________________________________________________________________

    @pytest.mark.xfail(
        "env.PYPY and env.MACOS",
        raises=RuntimeError,
        reason="Expected failure with PyPy and libc++ (Issue #2847 & PR #2999)",
    )
    def test_cross_module_exception_translator():
        with pytest.raises(KeyError):
            # translator registered in cross_module_tests
>           m.throw_should_be_translated_to_key_error()
E           RuntimeError

../../pybind11-2.8.1/tests/test_exceptions.py:82: RuntimeError
================================================================================== short test summary info ==================================================================================

Tests run from the port's 'test' target.

Version: 2.8.1
OS: FreeBSD 13

Reproducible example code

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with tests/test_exceptions.py and the test_cross_module_exception_translator failure, then inspect the cross_module_tests entry point and reproduce it through the port's test target on FreeBSD 13. Compare the reported pybind11 2.8.1 behavior with the expected KeyError and existing platform-specific xfail; done means the reported configuration is handled with the regression test passing.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, python
Domain
testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.