Bug 2486569 - Kickstart installs broken since Python 3.15 landed due to missing _math_integer module in initramfs environment
Summary: Kickstart installs broken since Python 3.15 landed due to missing _math_integ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: anaconda
Version: rawhide
Hardware: All
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Martin Kolman
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2026-06-08 22:24 UTC by Adam Williamson
Modified: 2026-06-17 08:16 UTC (History)
5 users (show)

Fixed In Version: anaconda-45.8-1.fc45
Clone Of:
Environment:
Last Closed: 2026-06-17 08:16:21 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github rhinstaller anaconda pull 7103 0 None open python-deps: add _math_integer if math is present 2026-06-08 22:45:32 UTC
Github rhinstaller anaconda pull 7104 0 None Draft dracut: include _math_integer module for Python 3.15+ 2026-06-09 15:56:02 UTC

Description Adam Williamson 2026-06-08 22:24:24 UTC
Since Python 3.15 landed in Rawhide, kickstart installs are broken. They fail with an error "Kickstart file /run/install/ks.cfg is missing." Examining the journal shows a traceback:

 Traceback (most recent call last):
   File "/sbin/parse-kickstart", line 35, in <module>
     from pykickstart.parser import KickstartParser, preprocessKickstart
   File "/usr/lib/python3.15/site-packages/pykickstart/parser.py", line 42, in <module>
     from pykickstart import constants, version
   File "/usr/lib/python3.15/site-packages/pykickstart/version.py", line 55, in <module>
     from pykickstart.load import load_to_str
   File "/usr/lib/python3.15/site-packages/pykickstart/load.py", line 20, in <module>
     import requests
   File "/usr/lib/python3.15/site-packages/requests/__init__.py", line 43, in <module>
     import urllib3
   File "/usr/lib/python3.15/site-packages/urllib3/__init__.py", line 14, in <module>
     from . import exceptions
   File "/usr/lib/python3.15/site-packages/urllib3/exceptions.py", line 7, in <module>
     from http.client import IncompleteRead as httplib_IncompleteRead
   File "/usr/lib64/python3.15/http/client.py", line 71, in <module>
     import email.parser
   File "/usr/lib64/python3.15/email/parser.py", line 12, in <module>
     from email.feedparser import FeedParser, BytesFeedParser
   File "/usr/lib64/python3.15/email/feedparser.py", line 27, in <module>
     from email._policybase import compat32
   File "/usr/lib64/python3.15/email/_policybase.py", line 10, in <module>
     from email.utils import _has_surrogates
   File "/usr/lib64/python3.15/email/utils.py", line 29, in <module>
     import urllib.parse
   File "/usr/lib64/python3.15/urllib/parse.py", line 36, in <module>
     import math
 ModuleNotFoundError: Standard library module '_math_integer' was not found

Ultimately this turns out to be an issue with the dracut/python-deps script - part of anaconda's custom dracut module setup. That script is used by dracut/module-setup.sh to find all the deps of the scripts we want to execute in the initramfs (dracut/parse-kickstart and dracut/driver_updates.py) and install them into the initramfs.

However, with Python 3.15, it seems to be missing a file. _math_integer is provided by /usr/lib64/python3.15/lib-dynload/_math_integer.cpython-315-x86_64-linux-gnu.so , but when you run python-deps on parse-kickstart , it does not list that file, so it does not get included in the initramfs on installer images, and that causes the failure.

I've come up with a minimal reproducer that shows this is actually missed by modulefinder.ModuleFinder (the stdlib dep finder user by python-deps):

<mock-chroot> sh-5.3# cat test.py
import math
<mock-chroot> sh-5.3# python3
>>> from modulefinder import ModuleFinder
>>> finder = ModuleFinder()
>>> finder.run_script("test.py")
>>> finder.modules
{'__main__': Module('__main__', 'test.py'), 'math': Module('math', '/usr/lib64/python3.15/lib-dynload/math.cpython-315-x86_64-linux-gnu.so')}
```
Note that `/usr/lib64/python3.15/lib-dynload/_math_integer.cpython-315-x86_64-linux-gnu.so` is not listed, but then watch this:
```
<mock-chroot> sh-5.3# python3 ./test.py
<mock-chroot> sh-5.3# mv /usr/lib64/python3.15/lib-dynload/_math_integer.cpython-315-x86_64-linux-gnu.so /var/tmp
<mock-chroot> sh-5.3# python3 ./test.py
Traceback (most recent call last):
  File "/builddir/./test.py", line 1, in <module>
    import math
ModuleNotFoundError: Standard library module '_math_integer' was not found

but I'm not sure if this is a bona fide bug in ModuleFinder, or if it's really python-deps' responsibility to deal with this somehow, so filing here first. I'm asking the Python team whether we should also file this as an upstream bug.

Comment 1 Adam Williamson 2026-06-08 22:45:33 UTC
https://github.com/rhinstaller/anaconda/pull/7103 works around this.

Comment 2 Adam Williamson 2026-06-09 15:56:02 UTC
rvykydal didn't see that I'd already filed this and also sent a PR - https://github.com/rhinstaller/anaconda/pull/7104

Comment 3 Fedora Update System 2026-06-17 06:54:49 UTC
FEDORA-2026-0328f2e801 (anaconda-45.8-1.fc45) has been submitted as an update to Fedora 45.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-0328f2e801

Comment 4 Fedora Update System 2026-06-17 08:16:21 UTC
FEDORA-2026-0328f2e801 (anaconda-45.8-1.fc45) has been pushed to the Fedora 45 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.