Skip to content

Conversation

@guitargeek
Copy link
Contributor

This avoids surprises where fragile test failures with C++17 and modules=OFF cannot be anticipated from the PR builds.

The test in question is in test_datatypes.py in the cppyy test suite:

=================================== FAILURES ===================================
____________________ TestDATATYPES.test49_addressof_method _____________________

self = <test.test_datatypes.TestDATATYPES object at 0x7fb5a77f3200>

    @mark.xfail(strict=True, condition=IS_MAC_ARM or IS_WINDOWS, reason="Crashes on mac-beta ARM64 and fails on Windows")
    def test49_addressof_method(self):
        """Use of addressof for (const) methods"""

        import cppyy

>       assert cppyy.addressof(cppyy.gbl.std.vector[int].at.__overload__(':any:', False))
E       AssertionError: assert 0
E        +  where 0 = <built-in function addressof>(<cppyy.CPPOverload object at 0x7fb5a7a62000>)
E        +    where <built-in function addressof> = <module 'cppyy' from '/github/home/ROOT-CI/build/lib/cppyy/__init__.py'>.addressof
E        +    and   <cppyy.CPPOverload object at 0x7fb5a7a62000> = <built-in method __overload__ of cppyy.CPPOverload object at 0x7fb5a7aaaa00>(':any:', False)
E        +      where <built-in method __overload__ of cppyy.CPPOverload object at 0x7fb5a7aaaa00> = <cppyy.CPPOverload object at 0x7fb5a7aaaa00>.__overload__
E        +        where <cppyy.CPPOverload object at 0x7fb5a7aaaa00> = <class cppyy.gbl.std.vector<int> at 0x5628463dfb40>.at

../../../../../../src/bindings/pyroot/cppyy/cppyy/test/test_datatypes.py:2348: AssertionError
----------------------------- Captured stderr call -----------------------------
input_line_412:2:106: error: 'RActivePhysicalColumns' is a protected member of 'ROOT::Internal::RPageSource'
 (vector<int>::reference (std::vector<int, std::allocator<int> >::*)(vector<ROOT::Internal::RPageSource::RActivePhysicalColumns::RColumnInfo>::size_type))&std::vector<int, std::allocator<int> >::at
                                                                                                         ^
/github/home/ROOT-CI/build/include/ROOT/RPageStorage.hxx:653:10: note: declared protected here
   class RActivePhysicalColumns {
         ^
=========================== short test summary info ============================

This avoids surprises where fragile test failures with C++17 and
modules=OFF cannot be anticipated from the PR builds.

The test in question is in `test_datatypes.py` in the cppyy test suite:
```txt
=================================== FAILURES ===================================
____________________ TestDATATYPES.test49_addressof_method _____________________

self = <test.test_datatypes.TestDATATYPES object at 0x7fb5a77f3200>

    @mark.xfail(strict=True, condition=IS_MAC_ARM or IS_WINDOWS, reason="Crashes on mac-beta ARM64 and fails on Windows")
    def test49_addressof_method(self):
        """Use of addressof for (const) methods"""

        import cppyy

>       assert cppyy.addressof(cppyy.gbl.std.vector[int].at.__overload__(':any:', False))
E       AssertionError: assert 0
E        +  where 0 = <built-in function addressof>(<cppyy.CPPOverload object at 0x7fb5a7a62000>)
E        +    where <built-in function addressof> = <module 'cppyy' from '/github/home/ROOT-CI/build/lib/cppyy/__init__.py'>.addressof
E        +    and   <cppyy.CPPOverload object at 0x7fb5a7a62000> = <built-in method __overload__ of cppyy.CPPOverload object at 0x7fb5a7aaaa00>(':any:', False)
E        +      where <built-in method __overload__ of cppyy.CPPOverload object at 0x7fb5a7aaaa00> = <cppyy.CPPOverload object at 0x7fb5a7aaaa00>.__overload__
E        +        where <cppyy.CPPOverload object at 0x7fb5a7aaaa00> = <class cppyy.gbl.std.vector<int> at 0x5628463dfb40>.at

../../../../../../src/bindings/pyroot/cppyy/cppyy/test/test_datatypes.py:2348: AssertionError
----------------------------- Captured stderr call -----------------------------
input_line_412:2:106: error: 'RActivePhysicalColumns' is a protected member of 'ROOT::Internal::RPageSource'
 (vector<int>::reference (std::vector<int, std::allocator<int> >::*)(vector<ROOT::Internal::RPageSource::RActivePhysicalColumns::RColumnInfo>::size_type))&std::vector<int, std::allocator<int> >::at
                                                                                                         ^
/github/home/ROOT-CI/build/include/ROOT/RPageStorage.hxx:653:10: note: declared protected here
   class RActivePhysicalColumns {
         ^
=========================== short test summary info ============================
```
@guitargeek guitargeek self-assigned this Jan 22, 2026
@guitargeek guitargeek requested a review from dpiparo as a code owner January 22, 2026 16:36
@guitargeek
Copy link
Contributor Author

This implements a suggestion by @dpiparo made in #20980 (comment)

@github-actions
Copy link

github-actions bot commented Jan 22, 2026

Test Results

    22 files      22 suites   3d 13h 24m 17s ⏱️
 3 766 tests  3 766 ✅ 0 💤 0 ❌
75 816 runs  75 816 ✅ 0 💤 0 ❌

Results for commit efd3c2d.

♻️ This comment has been updated with latest results.

@pcanal
Copy link
Member

pcanal commented Jan 22, 2026

This avoids surprises where fragile test failures with C++17 and modules=OFF cannot be anticipated from the PR builds.

Isn't that a platform we support though? (i.e. should both be in the PR builds). [Related: is the issue on our side or is it a compiler bug?]

@guitargeek
Copy link
Contributor Author

To me, this looks like a compiler or cling issue. I mean it's pretty crazy that this test...

    def test49_addressof_method(self):
        """Use of addressof for (const) methods"""

        import cppyy

        assert cppyy.addressof(cppyy.gbl.std.vector[int].at.__overload__(':any:', False))
        assert cppyy.addressof(cppyy.gbl.std.vector[int].at.__overload__(':any:', True))

...fails with this error:

error: 'RActivePhysicalColumns' is a protected member of 'ROOT::Internal::RPageSource'

It's worth to open a GitHub issue about it I guess. I'll do that later.

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.

2 participants