Bug 2537264

Summary: SSL AttributeError due to openssl 4.0/python3.15
Product: [Fedora] Fedora Reporter: Michele Baldessari <michele>
Component: offlineimapAssignee: serge-sans-paille <sergesanspaille>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 45CC: cfergeau, dodji, i, pbonzini, sergesanspaille
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: offlineimap-8.0.3-2.fc46 Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2026-09-21 09:55:36 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michele Baldessari 2026-09-20 18:32:39 UTC
ERROR: Exceptions occurred during the run!
ERROR: While attempting to sync account 'foo'
  AttributeError: module 'ssl' has no attribute 'PROTOCOL_TLSv1'. Did you mean '.PROTOCOL_TLS' instead of '.PROTOCOL_TLSv1'?


Traceback:
  File "/usr/lib/python3.15/site-packages/offlineimap/accounts.py", line 298, in syncrunner
    self.__sync()
    ~~~~~~~~~~~^^
  File "/usr/lib/python3.15/site-packages/offlineimap/accounts.py", line 378, in __sync
    remoterepos.getfolders()
    ~~~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.15/site-packages/offlineimap/repository/IMAP.py", line 700, in getfolders
    imapobj = self.imapserver.acquireconnection()
  File "/usr/lib/python3.15/site-packages/offlineimap/imapserver.py", line 638, in acquireconnection
    imapobj = imaplibutil.WrappedIMAP4_SSL(
        host=self.hostname,
    ...<11 lines>...
        af=self.af,
    )
  File "/usr/lib/python3.15/site-packages/offlineimap/imaplibutil.py", line 199, in __init__
    super(WrappedIMAP4_SSL, self).__init__(*args, **kwargs)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.15/site-packages/offlineimap/imaplib2.py", line 2124, in __init__
    IMAP4.__init__(self, host, port, debug, debug_file, identifier, timeout, debug_buf_lvl)
    ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.15/site-packages/offlineimap/imaplib2.py", line 357, in __init__
    self.open(host, port)
    ~~~~~~~~~^^^^^^^^^^^^
  File "/usr/lib/python3.15/site-packages/offlineimap/imaplibutil.py", line 207, in open
    super(WrappedIMAP4_SSL, self).open(host, port)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
  File "/usr/lib/python3.15/site-packages/offlineimap/imaplib2.py", line 2137, in open
    self.ssl_wrap_socket()
    ~~~~~~~~~~~~~~~~~~~~^^
  File "/usr/lib/python3.15/site-packages/offlineimap/imaplib2.py", line 491, in ssl_wrap_socket
    "tls1": ssl.PROTOCOL_TLSv1,
            ^^^^^^^^^^^^^^^^^^

Seems related to https://bugzilla.redhat.com/show_bug.cgi?id=2494735 and https://github.com/python/cpython/issues/152709

Reproducible: Always

Comment 1 serge-sans-paille 2026-09-20 21:51:07 UTC
@Michele, can you give a try to https://koji.fedoraproject.org/koji/taskinfo?taskID=150445500 ? It should fix the issue.

Comment 2 Michele Baldessari 2026-09-21 05:47:35 UTC
Works like a charm, thank you so much for the quick turnaround! :)

Comment 3 Fedora Update System 2026-09-21 09:50:58 UTC
FEDORA-2026-80b5cde60c (offlineimap-8.0.3-2.fc46) has been submitted as an update to Fedora 46.
https://bodhi.fedoraproject.org/updates/FEDORA-2026-80b5cde60c

Comment 4 Fedora Update System 2026-09-21 09:55:36 UTC
FEDORA-2026-80b5cde60c (offlineimap-8.0.3-2.fc46) has been pushed to the Fedora 46 stable repository.
If problem still persists, please make note of it in this bug report.