Bug 2356170 - conda fails to build with Python 3.14: tests/test_shell.py: TypeError: 'str' object cannot be interpreted as an integer
Summary: conda fails to build with Python 3.14: tests/test_shell.py: TypeError: 'str' ...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: conda
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Zbigniew Jędrzejewski-Szmek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3.14
TreeView+ depends on / blocked
 
Reported: 2025-03-31 09:03 UTC by Karolina Surma
Modified: 2025-03-31 09:03 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Karolina Surma 2025-03-31 09:03:00 UTC
conda fails to build with Python 3.14.0a6.

_____________________ ERROR collecting tests/test_shell.py _____________________
Traceback (most recent call last):
  File "/builddir/build/BUILD/conda-24.11.3-build/conda-24.11.3/conda/common/path/windows.py", line 92, in _path_to
    converted = subprocess.run(
                ~~~~~~~~~~~~~~^
        [cygpath, cygpath_arg, "--path", joined],
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<2 lines>...
        check=True,
        ^^^^^^^^^^^
    ).stdout.strip()
    ^
  File "/usr/lib64/python3.14/subprocess.py", line 554, in run
    with Popen(*popenargs, **kwargs) as process:
         ~~~~~^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.14/subprocess.py", line 1035, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
    ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                        pass_fds, cwd, env,
                        ^^^^^^^^^^^^^^^^^^^
    ...<5 lines>...
                        gid, gids, uid, umask,
                        ^^^^^^^^^^^^^^^^^^^^^^
                        start_new_session, process_group)
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.14/subprocess.py", line 1849, in _execute_child
    self._posix_spawn(args, executable, env, restore_signals, close_fds,
    ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                      p2cread, p2cwrite,
                      ^^^^^^^^^^^^^^^^^^
                      c2pread, c2pwrite,
                      ^^^^^^^^^^^^^^^^^^
                      errread, errwrite)
                      ^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.14/subprocess.py", line 1793, in _posix_spawn
    self.pid = os.posix_spawn(executable, args, env, **kwargs)
               ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/usr/bin/cygpath'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.14/site-packages/_pytest/runner.py", line 341, in from_call
    result: TResult | None = func()
                             ~~~~^^
  File "/usr/lib/python3.14/site-packages/_pytest/runner.py", line 389, in collect
    return list(collector.collect())
                ~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.14/site-packages/_pytest/python.py", line 549, in collect
    self._register_setup_module_fixture()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.14/site-packages/_pytest/python.py", line 562, in _register_setup_module_fixture
    self.obj, ("setUpModule", "setup_module")
    ^^^^^^^^
  File "/usr/lib/python3.14/site-packages/_pytest/python.py", line 284, in obj
    self._obj = obj = self._getobj()
                      ~~~~~~~~~~~~^^
  File "/usr/lib/python3.14/site-packages/_pytest/python.py", line 546, in _getobj
    return importtestmodule(self.path, self.config)
  File "/usr/lib/python3.14/site-packages/_pytest/python.py", line 493, in importtestmodule
    mod = import_path(
        path,
    ...<2 lines>...
        consider_namespace_packages=config.getini("consider_namespace_packages"),
    )
  File "/usr/lib/python3.14/site-packages/_pytest/pathlib.py", line 587, in import_path
    importlib.import_module(module_name)
    ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^
  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 1395, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1368, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1339, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "/usr/lib/python3.14/site-packages/_pytest/assertion/rewrite.py", line 184, in exec_module
    exec(co, module.__dict__)
    ~~~~^^^^^^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/conda-24.11.3-build/conda-24.11.3/tests/test_shell.py", line 89, in <module>
    class InteractiveShellType(type):
    ...<96 lines>...
            )
  File "/builddir/build/BUILD/conda-24.11.3-build/conda-24.11.3/tests/test_shell.py", line 90, in InteractiveShellType
    EXE = quote_for_shell(native_path_to_unix(sys.executable))
                          ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^
  File "/builddir/build/BUILD/conda-24.11.3-build/conda-24.11.3/conda/common/path/windows.py", line 149, in win_path_to_unix
    return _path_to(paths, prefix=prefix, cygdrive=cygdrive, to_unix=True)
  File "/builddir/build/BUILD/conda-24.11.3-build/conda-24.11.3/conda/common/path/windows.py", line 100, in _path_to
    log.warning("cygpath is not available, fallback to manual path conversion")
    ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.14/logging/__init__.py", line 1531, in warning
    self._log(WARNING, msg, args, **kwargs)
    ~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.14/logging/__init__.py", line 1664, in _log
    self.handle(record)
    ~~~~~~~~~~~^^^^^^^^
  File "/usr/lib64/python3.14/logging/__init__.py", line 1680, in handle
    self.callHandlers(record)
    ~~~~~~~~~~~~~~~~~^^^^^^^^
  File "/usr/lib64/python3.14/logging/__init__.py", line 1736, in callHandlers
    hdlr.handle(record)
    ~~~~~~~~~~~^^^^^^^^
  File "/usr/lib64/python3.14/logging/__init__.py", line 1021, in handle
    rv = self.filter(record)
  File "/usr/lib64/python3.14/logging/__init__.py", line 866, in filter
    result = f.filter(record)
  File "/builddir/build/BUILD/conda-24.11.3-build/conda-24.11.3/conda/gateways/logging.py", line 66, in filter
    record.msg = self.TOKEN_REPLACE(record.msg)
                 ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
TypeError: 'str' object cannot be interpreted as an integer

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/fedora-rawhide-x86_64/08837200-conda/

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

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/

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.


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