Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 931898 - dev-python/adblock-0.6.0 fails tests: test_engine.py::test_serde_file Fatal Python error: Aborted w/ python-3.13[debug]
Summary: dev-python/adblock-0.6.0 fails tests: test_engine.py::test_serde_file Fatal P...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Ionen Wolkens
URL:
Whiteboard:
Keywords: TESTFAILURE
Depends on:
Blocks:
 
Reported: 2024-05-14 07:24 UTC by Agostino Sarubbo
Modified: 2024-05-14 20:29 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,160.20 KB, text/plain)
2024-05-14 07:24 UTC, Agostino Sarubbo
Details
build.log with epytest -s (build.log,77.62 KB, text/plain)
2024-05-14 10:09 UTC, Ionen Wolkens
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2024-05-14 07:24:54 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-python/adblock-0.6.0 fails tests.
Discovered on: amd64 (internal ref: python3-13_tinderbox)
System: PYTHON-3.13-SYSTEM (https://wiki.gentoo.org/wiki/Project:Tinderbox/Common_Issues_Helper#GLIBC-2.39)

Info about the issue:
https://wiki.gentoo.org/wiki/Project:Tinderbox/Common_Issues_Helper#CF0015
Comment 1 Agostino Sarubbo gentoo-dev 2024-05-14 07:24:56 UTC
Created attachment 892913 [details]
build.log

build log and emerge --info
Comment 2 Agostino Sarubbo gentoo-dev 2024-05-14 07:24:56 UTC
Error(s) that match a know pattern in addition to what has been reported in the summary:


/var/tmp/portage/dev-python/adblock-0.6.0/temp/environment: line 2736:   234 Aborted                 "${@}"
tests/test_engine.py::test_serde_file Fatal Python error: Aborted
Comment 3 Ionen Wolkens gentoo-dev 2024-05-14 07:48:03 UTC
Haven't dug into it but needs 3.13 with USE=debug to reproduce it looks like (passes fine w/ 3.13 otherwise, and 3.12 is fine with USE=debug).

CC'ing python in case know something, *could* be some generalized rust extension issue w/ some crate need to know about or perhaps a bug in 3.13 itself. Not to this say this package itself may not just be doing something wrong (most crates are pretty old too, including pyo3).

Note nothing need this package with 3.13 atm, only added 3.13 to test maturin.
Comment 4 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2024-05-14 08:07:00 UTC
Run pytest with `-s` to see the actual assertion.
Comment 5 Ionen Wolkens gentoo-dev 2024-05-14 10:09:48 UTC
Created attachment 892915 [details]
build.log with epytest -s

(In reply to Michał Górny from comment #4)
> Run pytest with `-s` to see the actual assertion.
tests/test_engine.py::test_serde_file python3.13: ./Include/internal/pycore_object.h:284: _PyObject_Init: Assertion `_PyType_HasFeature(typeobj, Py_TPFLAGS_HEAPTYPE) || _Py_IsImmortal(typeobj)' failed.
Fatal Python error: Aborted
Comment 6 Ionen Wolkens gentoo-dev 2024-05-14 10:15:49 UTC
Haven't dug into why it's failing, but assert[1] is new in 3.13[2]

[1] https://github.com/python/cpython/blob/e237b25a4/Include/internal/pycore_object.h#L284
[2] https://github.com/python/cpython/commit/c32dc47ac
Comment 7 Ionen Wolkens gentoo-dev 2024-05-14 20:16:35 UTC
From a peek at the test, this is likely specific to this package given it's working on a missing file and probably misses a step to handle this:

    engine0 = empty_engine()
    with pytest.raises(FileNotFoundError):
        # We haven't created the cache.dat file, so we should get an exception
        # when attempting to deserialize.
        engine0.deserialize_from_file(path)

Should have no impact for normal usage and given upstream is kind of dead maybe I'll just skip that test.
Comment 8 Ionen Wolkens gentoo-dev 2024-05-14 20:19:03 UTC
(wanted to try newer pyo3 but the farthest it can go without breaking is 0.16.6)
Comment 9 Larry the Git Cow gentoo-dev 2024-05-14 20:29:19 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=116fc042867c8cc0584a5aac64179eff7d02ca1c

commit 116fc042867c8cc0584a5aac64179eff7d02ca1c
Author:     Ionen Wolkens <ionen@gentoo.org>
AuthorDate: 2024-05-14 20:28:47 +0000
Commit:     Ionen Wolkens <ionen@gentoo.org>
CommitDate: 2024-05-14 20:29:06 +0000

    dev-python/adblock: skip test_serde_file
    
    Closes: https://bugs.gentoo.org/931898
    Signed-off-by: Ionen Wolkens <ionen@gentoo.org>

 dev-python/adblock/adblock-0.6.0.ebuild | 3 +++
 1 file changed, 3 insertions(+)