Bug 2366471

Summary: ephemeral-port-reserve fails to build with Python 3.14: socket.gaierror: [Errno -3] Temporary failure in name resolution
Product: [Fedora] Fedora Reporter: Karolina Surma <ksurma>
Component: ephemeral-port-reserveAssignee: Charalampos Stratakis <cstratak>
Status: CLOSED ERRATA QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: carl, cstratak, ksurma, mhroncok
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ephemeral-port-reserve-1.1.4-12.fc43 ephemeral-port-reserve-1.1.4-12.fc42 Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-05-29 05:11:00 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Karolina Surma 2025-05-15 10:54:25 UTC
ephemeral-port-reserve fails to build with Python 3.14.0b1.

============================= test session starts ==============================
platform linux -- Python 3.14.0b1, pytest-8.3.5, pluggy-1.5.0
rootdir: /builddir/build/BUILD/ephemeral-port-reserve-1.1.4-build/ephemeral-port-reserve-1.1.4
collected 4 items

tests/ephemeral_port_test.py .F..                                        [100%]

=================================== FAILURES ===================================
__________________________________ test_fqdn ___________________________________

    def test_fqdn():
>       fqip = socket.gethostbyname(getfqdn())
E       socket.gaierror: [Errno -3] Temporary failure in name resolution

tests/ephemeral_port_test.py:48: gaierror

https://docs.python.org/3.14/whatsnew/3.14.html

For the build logs, see:
https://copr-be.cloud.fedoraproject.org/results/@python/python3.14-b1/fedora-rawhide-x86_64/09024351-ephemeral-port-reserve/

For all our attempts to build ephemeral-port-reserve with Python 3.14, see:
https://copr.fedorainfracloud.org/coprs/g/python/python3.14-b1/package/ephemeral-port-reserve/

Testing and mass rebuild of packages is happening in copr.
You can follow these instructions to test locally in mock if your package builds with Python 3.14:
https://copr.fedorainfracloud.org/coprs/g/python/python3.14-b1/

Let us know here if you have any questions.

Python 3.14 is planned to be included in Fedora 43.
To make that update smoother, we're building Fedora packages with all pre-releases of Python 3.14.
A build failure prevents us from testing all dependent packages (transitive [Build]Requires),
so if this package is required a lot, it's important for us to get it fixed soon.

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 Charalampos Stratakis 2025-05-29 00:24:14 UTC
This is failing possibly due to a glibc update from 2.40 to 2.41, it's unrelated to Python3.14.

Comment 2 Charalampos Stratakis 2025-05-29 00:54:26 UTC
On Fedora < 42:

from socket import getfqdn
getfqdn()
'localhost.localdomain'

Which will get resolved usually in 127.0.0.1 e.g. with socket.gethostbyname(getfqdn())

But on Fedora >= 42
getfqdn()
'3f93fd8e1d304e40ba598b3f15c41c11'

Which obviously cannot get resolved, hence the test fails at "socket.gethostbyname(getfqdn())" with "socket.gaierror: [Errno -3] Temporary failure in name resolution"

Comment 3 Charalampos Stratakis 2025-05-29 01:08:30 UTC
This could also be due to mock assigning the hostname to the image ID instead of the previous default.

Comment 4 Charalampos Stratakis 2025-05-29 01:45:20 UTC
Not sure where the change was implemented but basically we'll have to just fallback to 127.0.0.1 if getfqdn() fails.

Upstream is abandoned. I'll prepare a patch.

Comment 5 Charalampos Stratakis 2025-05-29 02:37:31 UTC
The issue here is that systemd has been removed from the dependency chain (or the buildroot or something) from F42 and onwoards, hence it doesn't create a hostname.

Comment 6 Fedora Update System 2025-05-29 05:07:45 UTC
FEDORA-2025-323ca9e288 (ephemeral-port-reserve-1.1.4-12.fc43) has been submitted as an update to Fedora 43.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-323ca9e288

Comment 7 Fedora Update System 2025-05-29 05:11:00 UTC
FEDORA-2025-323ca9e288 (ephemeral-port-reserve-1.1.4-12.fc43) has been pushed to the Fedora 43 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 8 Fedora Update System 2025-05-29 05:16:15 UTC
FEDORA-2025-d81affa66a (ephemeral-port-reserve-1.1.4-12.fc42) has been submitted as an update to Fedora 42.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-d81affa66a

Comment 9 Fedora Update System 2025-05-30 02:21:43 UTC
FEDORA-2025-d81affa66a has been pushed to the Fedora 42 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2025-d81affa66a`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2025-d81affa66a

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 10 Fedora Update System 2025-06-07 06:45:48 UTC
FEDORA-2025-d81affa66a (ephemeral-port-reserve-1.1.4-12.fc42) has been pushed to the Fedora 42 stable repository.
If problem still persists, please make note of it in this bug report.