Bug 2326430 - Alot: No module named 'mailcap'
Summary: Alot: No module named 'mailcap'
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: alot
Version: 41
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: ---
Assignee: Tomas Tomecek
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2024-11-15 09:56 UTC by Dick Marinus
Modified: 2025-05-10 01:17 UTC (History)
2 users (show)

Fixed In Version: alot-0.10-8.fc41 alot-0.11-7.fc42
Clone Of:
Environment:
Last Closed: 2025-05-01 03:11:32 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github pazz alot issues 1632 0 None open mailcap is deprecated in Python 3.11 and will be removed in 3.13 2024-11-15 09:56:37 UTC
Red Hat Bugzilla 2328464 0 medium CLOSED Review Request: python-standard-mailcap - restore removed mailcap dead battery 2025-04-21 16:46:52 UTC

Description Dick Marinus 2024-11-15 09:56:38 UTC
Description of problem:


Version-Release number of selected component (if applicable): alot-0.10-5.fc41.noarch


How reproducible:


Steps to Reproduce:
1. dnf install alot
2. run alot

Actual results:

Traceback (most recent call last):
  File "/usr/bin/alot", line 33, in <module>
    sys.exit(load_entry_point('alot==0.10', 'console_scripts', 'alot')())
             ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/bin/alot", line 25, in importlib_load_entry_point
    return next(matches).load()
           ~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib64/python3.13/importlib/metadata/__init__.py", line 179, in load
    module = import_module(match.group('module'))
  File "/usr/lib64/python3.13/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 1022, in exec_module
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "/usr/lib/python3.13/site-packages/alot/__main__.py", line 10, in <module>
    from alot.settings.const import settings
  File "/usr/lib/python3.13/site-packages/alot/settings/const.py", line 4, in <module>
    from .manager import SettingsManager
  File "/usr/lib/python3.13/site-packages/alot/settings/manager.py", line 7, in <module>
    import mailcap


Expected results:

No errors

Additional info:

Mailcap has been removed from Python 3.13 (as a dead battery).

There's a community project that has created https://pypi.org/project/standard-mailcap/

I've created a specfile for it using p2py: https://copr-dist-git.fedorainfracloud.org/cgit/meeuw/alot/python-standard-mailcap.git/tree/python-standard-mailcap.spec?h=f41

Not sure if this should be added to the Fedora repositories.

Comment 1 Tomas Tomecek 2024-11-18 09:01:14 UTC
Fascinating, I wasn't aware of this. They retired quite a lot of modules. I'm sure the removal affects much more packages.

Here is an upstream issue: https://github.com/pazz/alot/issues/1632

I am going to ask on Fedora Python matrix channel in the meantime.

Comment 2 Tomas Tomecek 2024-11-18 12:43:36 UTC
Miro Hroncok suggested packaging mailcap:

"mhroncok: hi. no such plan exists. if there is a PyPI-packaged maintained replacement, you (anybody) can package it"

> I've created a specfile for it using p2py: https://copr-dist-git.fedorainfracloud.org/cgit/meeuw/alot/python-standard-mailcap.git/tree/python-standard-mailcap.spec?h=f41
> Not sure if this should be added to the Fedora repositories.

Feel free to start the new package process if you are interested. Dick, I am also happy to give you commit access to alot since you are actually using it :)

Comment 3 Dick Marinus 2024-11-23 07:51:00 UTC
Please do! I've started the new package process for mailcap:

https://bugzilla.redhat.com/show_bug.cgi?id=2328464

Comment 4 Tomas Tomecek 2024-11-25 08:52:45 UTC
I'm late /o\ but I can see you got positive feedback, well done!

I'll rebuild alot once you land mailcap in rawhide. Thank you for your effort!

Comment 5 Fedora Update System 2025-04-21 19:06:55 UTC
FEDORA-2025-6975b10e40 (alot-0.11-5.fc42) has been submitted as an update to Fedora 42.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-6975b10e40

Comment 6 Fedora Update System 2025-04-22 01:46:44 UTC
FEDORA-2025-6975b10e40 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-6975b10e40`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2025-6975b10e40

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

Comment 7 Fedora Update System 2025-04-22 09:22:26 UTC
FEDORA-2025-6d6e9a2e27 (alot-0.10-8.fc41) has been submitted as an update to Fedora 41.
https://bodhi.fedoraproject.org/updates/FEDORA-2025-6d6e9a2e27

Comment 8 Fedora Update System 2025-04-23 03:26:10 UTC
FEDORA-2025-6d6e9a2e27 has been pushed to the Fedora 41 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-6d6e9a2e27`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2025-6d6e9a2e27

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

Comment 9 Fedora Update System 2025-05-01 03:11:32 UTC
FEDORA-2025-6d6e9a2e27 (alot-0.10-8.fc41) has been pushed to the Fedora 41 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 10 Fedora Update System 2025-05-02 03:26:40 UTC
FEDORA-2025-f0d8b1b39b 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-f0d8b1b39b`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2025-f0d8b1b39b

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

Comment 11 Fedora Update System 2025-05-10 01:17:29 UTC
FEDORA-2025-f0d8b1b39b (alot-0.11-7.fc42) has been pushed to the Fedora 42 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.