Bug 2414808 - import aexpect crashes with: No module named 'pipes' (pipes removed from python3.13+)
Summary: import aexpect crashes with: No module named 'pipes' (pipes removed from pyth...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: python-aexpect
Version: 43
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: fedepell
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-11-13 11:56 UTC by Henryk Paluch (Work)
Modified: 2026-10-05 08:09 UTC (History)
2 users (show)

Fixed In Version: python-aexpect-1.8.0-1.fc46 python-aexpect-1.8.0-1.fc45
Clone Of:
Environment:
Last Closed: 2026-09-14 04:13:40 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Henryk Paluch (Work) 2025-11-13 11:56:38 UTC
python3-aexpect package is unusable, because it depends on 'pipes' python module that was removed from python 3.13+ (Fedora 43 uses python 3.14).


Detailed versions:

$ cat /etc/fedora-release 

Fedora release 43 (Forty Three)

$ rpm -q python3 python3-aexpect

python3-3.14.0-2.fc43.x86_64
python3-aexpect-1.6.2-18.fc43.noarch

This breaks dependent packages (any command from python3-avocado-plugins-vt)



Reproducible: Always

Steps to Reproduce:
1. sudo dnf install python3-aexpect
2. python -c 'import aexpect'

Actual Results:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
    import aexpect
  File "/usr/lib/python3.14/site-packages/aexpect/__init__.py", line 35, in <module>
    from . import remote
  File "/usr/lib/python3.14/site-packages/aexpect/remote.py", line 50, in <module>
    import pipes
ModuleNotFoundError: No module named 'pipes'



Expected Results:
No error on output

Additional Information:
There are similar projects hit by same issue, for example: https://github.com/jupyter/nbclassic/pull/286/files or official https://peps.python.org/pep-0594/#pipes

Possible resolution is to replace "pipes" with "shlex" as shown on https://github.com/jupyter/nbclassic/pull/286/files

Comment 1 Henryk Paluch (Work) 2025-11-13 12:16:16 UTC
Crude workaround:

$ sudo sed -i.bak -e 's/pipes/shlex/' /usr/lib/python3.14/site-packages/aexpect/remote.py

With that command:

$ python -c 'import aexpect'

finishes properly (no error, no output).

Comment 2 Henryk Paluch (Work) 2025-11-13 12:58:09 UTC
There is even PR https://github.com/avocado-framework/aexpect/pull/128 but for some unknown reason it is not in Fedora package (yes, aexpect belongs to Avocado VT, but is provided by base "fedora" repository - so bugzilla is right place for report):

Detailed broken package info:

$ dnf info python3-aexpect
Updating and loading repositories:
Repositories loaded.
Installed packages
Name            : python3-aexpect
Epoch           : 0
Version         : 1.6.2
Release         : 18.fc43
Architecture    : noarch
Installed size  : 510.9 KiB
Source          : python-aexpect-1.6.2-18.fc43.src.rpm
From repository : fedora
Summary         : A python library to control interactive applications
URL             : https://github.com/avocado-framework/aexpect
License         : GPL-2.0-or-later
Description     : Aexpect is a python library used to control interactive applications, very
                : similar to pexpect. You can use it to control applications such as ssh, scp
                : sftp, telnet, among others.
Vendor          : Fedora Project

Comment 3 Henryk Paluch (Work) 2025-11-13 13:24:35 UTC
Upstream fixed it in Version 1.8.0 as published on: https://github.com/avocado-framework/aexpect/releases/tag/1.8.0

What's Changed

...
    Drop the use of pipes by @luckyh in #128
...

Rebuilding package for 1.8.0 (tagged on Jul 30, 2025) instead of existing 1.6.2 (tagged on Jun 2, 2021) should fix this bug.

Comment 4 Fedora Update System 2026-09-14 04:11:13 UTC
FEDORA-2026-3f5d0869ce (python-aexpect-1.8.0-1.fc46) has been submitted as an update to Fedora 46.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-3f5d0869ce

Comment 5 Fedora Update System 2026-09-14 04:13:40 UTC
FEDORA-2026-3f5d0869ce (python-aexpect-1.8.0-1.fc46) has been pushed to the Fedora 46 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 6 Fedora Update System 2026-09-14 04:23:45 UTC
FEDORA-2026-71afe15d60 (python-aexpect-1.8.0-1.fc45) has been submitted as an update to Fedora 45.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-71afe15d60

Comment 7 Fedora Update System 2026-09-15 01:25:46 UTC
FEDORA-2026-71afe15d60 has been pushed to the Fedora 45 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-71afe15d60`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2026-71afe15d60

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

Comment 8 Fedora Update System 2026-09-23 00:15:46 UTC
FEDORA-2026-71afe15d60 (python-aexpect-1.8.0-1.fc45) has been pushed to the Fedora 45 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 9 Henryk Paluch (Work) 2026-09-23 05:01:50 UTC
Hello!

Is there plan to push fixed 1.8.0 to current stable Fedora 44?

As existing 1.6.2 is completely broken on F44 (crashes on module import) there is no harm in upgrading that package on F44 (it could only improve current state of affairs).

Comment 10 fedepell 2026-09-29 02:26:59 UTC
Sorry it took a white to respond as I was (finally ;) ) on a short summer break. Coming in a moment for F44!

Comment 11 Henryk Paluch (Work) 2026-10-05 08:01:27 UTC
Fedora 44 Testing repo works fine for me using: https://bodhi.fedoraproject.org/updates/FEDORA-2026-3894e1d518

$ sudo dnf install python3-aexpect
$ rpm -q python3-aexpect

python3-aexpect-1.6.2-19.fc44.noarch

expected failure from command below:

$ python3 -c "import aexpect"

Traceback (most recent call last):
  File "<string>", line 1, in <module>
    import aexpect
  File "/usr/lib/python3.14/site-packages/aexpect/__init__.py", line 35, in <module>
    from . import remote
  File "/usr/lib/python3.14/site-packages/aexpect/remote.py", line 50, in <module>
    import pipes
ModuleNotFoundError: No module named 'pipes'

$ sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2026-3894e1d518
$ rpm -q python3-aexpect # must return 1.8.0 or higher

python3-aexpect-1.8.0-1.fc44.noarch
 
import should now work properly:

$ python3 -c "import aexpect"

OK: no output


Looking forward once it reach Updates repo.

Comment 12 fedepell 2026-10-05 08:09:27 UTC
Thanks for testing and sorry for the delay (actually I built it the day I commented..... and forgot update eww :/ )

If you have a Fedora account and want to +1 the update in Bodhi, it would speed up landing in F44 :)

Thanks!


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