Bug 2371667

Summary: Rebuild tmt against Python 3.14
Product: [Fedora] Fedora Reporter: Petr Pisar <ppisar>
Component: tmtAssignee: Petr Šplíchal <psplicha>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: fedora, lzachar, mhlavink, mhoyer, mizdebsk, mvadkert, orion, psplicha, tbajer
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2025-12-19 03:48:10 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:
Bug Depends On: 2372054    
Bug Blocks:    

Description Petr Pisar 2025-06-11 07:43:34 UTC
A new Python 3.14 (python3-3.14.0~b2-3.fc43.x86_64) just landed into Fedora 43 but tmt was not rebuilt against it. As a result, tmt-1.50.0-1.fc43.noarch cannot be installed:

# LC_ALL=en_US dnf -q install tmt
Failed to resolve the transaction:
Problem: conflicting requests
  - nothing provides python(abi) = 3.13 needed by tmt-1.50.0-1.fc43.noarch from f43-build

Please rebuild tmt.

Comment 1 Petr Šplíchal 2025-06-16 16:38:15 UTC
This is currently blocked by the missing `python3-pydantic`: BZ#2372054

Comment 2 Mikolaj Izdebski 2025-07-07 08:16:30 UTC
python3-pydantic is available, please rebuild tmt against Python 3.14 in rawhide.

Comment 3 Orion Poplawski 2025-07-27 20:15:06 UTC
Thre is a test failure now:

+ /usr/bin/python3 -sP /usr/lib/rpm/redhat/import_all_modules.py -f /builddir/build/BUILD/tmt-1.50.0-build/tmt-1.50.0-1.fc43.noarch-pyproject-modules
Check import: tmt
Traceback (most recent call last):
  File "/usr/lib/rpm/redhat/import_all_modules.py", line 171, in <module>
    main()
    ~~~~^^
  File "/usr/lib/rpm/redhat/import_all_modules.py", line 167, in main
    import_modules(modules)
    ~~~~~~~~~~~~~~^^^^^^^^^
  File "/usr/lib/rpm/redhat/import_all_modules.py", line 100, in import_modules
    importlib.import_module(module)
    ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
  File "/usr/lib64/python3.14/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1398, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1371, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1342, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 938, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 762, in exec_module
  File "<frozen importlib._bootstrap>", line 491, in _call_with_frames_removed
  File "/builddir/build/BUILD/tmt-1.50.0-build/BUILDROOT/usr/lib/python3.14/site-packages/tmt/__init__.py", line 23, in <module>
    from tmt.base import Clean, Plan, Run, Status, Story, Test, Tree
  File "/builddir/build/BUILD/tmt-1.50.0-build/BUILDROOT/usr/lib/python3.14/site-packages/tmt/base.py", line 43, in <module>
    import tmt.config
  File "/builddir/build/BUILD/tmt-1.50.0-build/BUILDROOT/usr/lib/python3.14/site-packages/tmt/config/__init__.py", line 15, in <module>
    from tmt.config.models.themes import Theme, ThemeConfig
  File "/builddir/build/BUILD/tmt-1.50.0-build/BUILDROOT/usr/lib/python3.14/site-packages/tmt/config/models/themes.py", line 14, in <module>
    class Style(MetadataContainer):
    ...<18 lines>...
            return _style(text, **self.dict())
  File "/usr/lib/python3.14/site-packages/pydantic/v1/main.py", line 221, in __new__
    inferred = ModelField.infer(
        name=var_name,
    ...<3 lines>...
        config=config,
    )
  File "/usr/lib/python3.14/site-packages/pydantic/v1/fields.py", line 504, in infer
    return cls(
        name=name,
    ...<7 lines>...
        field_info=field_info,
    )
  File "/usr/lib/python3.14/site-packages/pydantic/v1/fields.py", line 434, in __init__
    self.prepare()
    ~~~~~~~~~~~~^^
  File "/usr/lib/python3.14/site-packages/pydantic/v1/fields.py", line 544, in prepare
    self._set_default_and_type()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.14/site-packages/pydantic/v1/fields.py", line 576, in _set_default_and_type
    raise errors_.ConfigError(f'unable to infer type for attribute "{self.name}"')
pydantic.v1.errors.ConfigError: unable to infer type for attribute "fg"

which might still be an issue in pydantic.

Filed with tmt - https://github.com/teemtee/tmt/issues/3918

Comment 4 Cristian Le 2025-12-19 03:48:10 UTC
This was resolved a while ago