Bug 2293082 - python-pikepdf fails to build with Python 3.13 in Fedora Rawhide (41): test_page_attrs: AssertionError: Regex pattern did not match.
Summary: python-pikepdf fails to build with Python 3.13 in Fedora Rawhide (41): test_p...
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: python-pikepdf
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Elliott Sales de Andrade
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: F41FTBFS PYTHON3.13
TreeView+ depends on / blocked
 
Reported: 2024-06-19 14:31 UTC by Karolina Surma
Modified: 2024-06-19 23:19 UTC (History)
5 users (show)

Fixed In Version: python-pikepdf-9.0.0-2.fc41
Clone Of:
Environment:
Last Closed: 2024-06-19 23:19:02 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Karolina Surma 2024-06-19 14:31:42 UTC
python-pikepdf fails to build with Python 3.13 in Fedora Rawhide (41).

Build failure:

_______________________________ test_page_attrs ________________________________
[gw9] linux -- Python 3.13.0 /usr/bin/python3
graph = <pikepdf.Pdf description='/builddir/build/BUILD/python-pikepdf-8.8.0-build/pikepdf-8.8.0/tests/resources/graph.pdf'>
    def test_page_attrs(graph):
        # Test __getattr__
        assert isinstance(graph.pages[0].Resources, Dictionary)
    
        del graph.pages[0].Resources
        with pytest.raises(
            AttributeError, match=r"can't delete|property of 'Page' object has no deleter"
        ):
>           del graph.pages[0].obj
tests/test_page.py:295: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
self = <pikepdf.Page({
  "/Contents": pikepdf.Stream(owner=<...>, data=b'q\n545.280000 0 0 443'..., {
    "/Length": 44
  }),...diaBox": [ 0, 0, Decimal('545.2800'), Decimal('443.5200') ],
  "/Parent": <reference to /Pages>,
  "/Type": "/Page"
})>
name = 'obj'
    @augment_override_cpp
    def __delattr__(self, name):
        if hasattr(self.__class__, name):
>           object.__delattr__(self, name)
E           AttributeError: property '' of 'Page' object has no deleter
../BUILDROOT/usr/lib64/python3.13/site-packages/pikepdf/_methods.py:1293: AttributeError
During handling of the above exception, another exception occurred:
graph = <pikepdf.Pdf description='/builddir/build/BUILD/python-pikepdf-8.8.0-build/pikepdf-8.8.0/tests/resources/graph.pdf'>
    def test_page_attrs(graph):
        # Test __getattr__
        assert isinstance(graph.pages[0].Resources, Dictionary)
    
        del graph.pages[0].Resources
>       with pytest.raises(
            AttributeError, match=r"can't delete|property of 'Page' object has no deleter"
        ):
E       AssertionError: Regex pattern did not match.
E        Regex: "can't delete|property of 'Page' object has no deleter"
E        Input: "property '' of 'Page' object has no deleter"
tests/test_page.py:292: AssertionError
=========================== short test summary info ============================
FAILED tests/test_page.py::test_page_attrs - AssertionError: Regex pattern di...
======= 1 failed, 615 passed, 8 skipped, 1 xfailed, 1 warning in 10.28s ========


Let us know here if you have any questions.
Python 3.13 is planned to be included in Fedora 41.


Note You need to log in before you can comment on or make changes to this bug.