Bug 2273337 - jrnl fails to build with pytest 8: Tests are failing with pytest 8.1
Summary: jrnl fails to build with pytest 8: Tests are failing with pytest 8.1
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: jrnl
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Ben Beasley
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 2256331
TreeView+ depends on / blocked
 
Reported: 2024-04-04 09:37 UTC by Tomáš Hrnčiar
Modified: 2024-08-13 00:30 UTC (History)
3 users (show)

Fixed In Version: jrnl-4.1-9.fc41 jrnl-4.1-11.fc41
Clone Of:
Environment:
Last Closed: 2024-07-30 15:21:39 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github jrnl-org jrnl issues 1879 0 None open Tests are failing with pytest 8.1 2024-04-04 09:37:20 UTC

Description Tomáš Hrnčiar 2024-04-04 09:37:21 UTC
jrnl fails to build with pytest 8.

This report is automated and not very verbose, but we'll try to get back here with details.
Tracked upstream.

https://docs.pytest.org/en/stable/changelog.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/thrnciar/pytest/fedora-rawhide-x86_64/07247588-jrnl/

For all our attempts to build jrnl with pytest 8, see:
https://copr.fedorainfracloud.org/coprs/thrnciar/pytest/package/jrnl/

Let us know here if you have any questions.

Pytest 8 is planned to be included in Fedora 41. And this bugzilla is a
heads up before we merge new pytest into rawhide. For more info see a Fedora Change
proposal https://fedoraproject.org/wiki/Changes/Pytest_8

We'd appreciate help from the people who know this package best,
but if you don't want to work on this now, let us know so we can try to work around it on our side.

Comment 1 Ben Beasley 2024-04-05 17:41:42 UTC
================= 243 failed, 396 passed, 40 skipped in 6.12s ==================

Upstream is aware, https://github.com/jrnl-org/jrnl/issues/1879, but does not yet have a fix.

I’m willing to skip the (very many) affected tests or temporarily disable the tests if upstream doesn’t come up with something before you are otherwise ready to ship pytest 8.

Comment 2 Tomáš Hrnčiar 2024-04-08 07:57:01 UTC
I think we can wait for the upstream's reaction. I don't plan to ship pytest 8 in the immediate future. There are plenty of packages that still need to be fixed and I don't want to disrupt Python 3.13 effort. Unless they are miraculously fixed quickly I'd like to ship pytest after Python 3.13 mass rebuild in June/July.

Comment 3 Tomáš Hrnčiar 2024-07-23 08:08:17 UTC
@code I'd like to ship pytest 8 soon and it seems like there is no progress regarding this issue in the upstream. We can either use pytest 8 and skip the failing tests or use the python-pytest7 compat package for now. What do you prefer?

Comment 4 Ben Beasley 2024-07-23 13:37:18 UTC
Is there a COPR that I can use to try jrnl with pytest 8, so I can see exactly which tests are failing in Fedora? It doesn’t seem like https://copr.fedorainfracloud.org/coprs/thrnciar/pytest/ is current.

Comment 5 Ben Beasley 2024-07-23 13:55:02 UTC
Assuming there are still 243 failing tests on pytest 8, and a python-pytest7 compat package is already planned, then I would be inclined to use the compat package for now so that I have good test coverage and an early warning about any compatibility issues with *other* updates.

If, in the future, there are fewer packages depending on pytest 7 and jrnl starts standing in the way of retiring the compat package, then I would reconsider. Hopefully upstream will figure out the right fix before that happens.

Comment 6 Tomáš Hrnčiar 2024-07-30 12:39:07 UTC
Yeah, there are still 243 failing tests. You can use this COPR for testing: https://copr.fedorainfracloud.org/coprs/thrnciar/pytest-8.3.1/
Currently, we have 10 packages that will need compat package (including jrnl).

Comment 7 Ben Beasley 2024-07-30 13:40:34 UTC
(In reply to Tomáš Hrnčiar from comment #6)
> Yeah, there are still 243 failing tests. You can use this COPR for testing:
> https://copr.fedorainfracloud.org/coprs/thrnciar/pytest-8.3.1/
> Currently, we have 10 packages that will need compat package (including
> jrnl).

Thanks, that’s very helpful.

I investigated whether this was due to https://github.com/pytest-dev/pytest-bdd/issues/689, but applying https://github.com/pytest-dev/pytest-bdd/pull/690 as a downstream patch to python-pytest-bdd didn’t seem to make any difference.

I’ll open a PR on jrnl to use the python-pytest7 compat package for now.

It’s really awkward to skip just the failing tests, because they have names like

  test_create_entry_using_day_of_the_week_as_entry_date_one[sunday: entry on a sunday-entry on a sunday-2019-03-10 09:00]

that create quoting and escaping difficulties, and if I skip just the base names of the failing tests, e.g. test_create_entry_using_day_of_the_week_as_entry_date_one above, then I end up disabling *all* of the tests. So if this isn’t fixed in the next few months and jrnl ends up being one of the last users of the compat package, I’ll just end up disabling the tests and doing %pyproject_check_import only. I followed up upstream in https://github.com/jrnl-org/jrnl/issues/1879#issuecomment-2258379926.

Comment 8 Fedora Update System 2024-07-30 14:48:34 UTC
FEDORA-2024-e9ec653813 (jrnl-4.1-9.fc41) has been submitted as an update to Fedora 41.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-e9ec653813

Comment 9 Fedora Update System 2024-07-30 15:21:39 UTC
FEDORA-2024-e9ec653813 (jrnl-4.1-9.fc41) has been pushed to the Fedora 41 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Tomáš Hrnčiar 2024-07-31 09:49:14 UTC
Thank you for the help!

Comment 11 Fedora Update System 2024-08-13 00:26:03 UTC
FEDORA-2024-9912bd663b (jrnl-4.1-11.fc41) has been submitted as an update to Fedora 41.
https://bodhi.fedoraproject.org/updates/FEDORA-2024-9912bd663b

Comment 12 Fedora Update System 2024-08-13 00:30:05 UTC
FEDORA-2024-9912bd663b (jrnl-4.1-11.fc41) has been pushed to the Fedora 41 stable repository.
If problem still persists, please make note of it in this bug report.


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