-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ansible: mail integration tests uses the asyncore module which has been removed in Python 3.11 #4656
Comments
Files identified in the description: If these files are incorrect, please update the |
!component =tests/integration/targets/mail/files/smtpserver.py |
Link to the line importing asyncore:
|
Files identified in the description: If these files are incorrect, please update the |
Thanks for this report! Instead of vendoring that module, I think we should better adjust the test. |
The same test also depends on the smtpd module, which will be removed from Python 3.12. I was about to suggest the following route:
Right now I'm more thinking of installing and configuring something like postfix instead? That's probably more work, but seems less painful to maintain. |
* devel supports Fedora 39, and no longer Fedora 38. * Disable 'mail' tests for Python 3.12+. Ref: #4656 * Fix setupSSLServer to work with Python 3.12.
…and no longer Fedora 38 (#7547) CI: devel supports Fedora 39, and no longer Fedora 38 (#7541) * devel supports Fedora 39, and no longer Fedora 38. * Disable 'mail' tests for Python 3.12+. Ref: #4656 * Fix setupSSLServer to work with Python 3.12. (cherry picked from commit b8ecb16) Co-authored-by: Felix Fontein <[email protected]>
…and no longer Fedora 38 (#7548) CI: devel supports Fedora 39, and no longer Fedora 38 (#7541) * devel supports Fedora 39, and no longer Fedora 38. * Disable 'mail' tests for Python 3.12+. Ref: #4656 * Fix setupSSLServer to work with Python 3.12. (cherry picked from commit b8ecb16) Co-authored-by: Felix Fontein <[email protected]>
…tions#7541) * devel supports Fedora 39, and no longer Fedora 38. * Disable 'mail' tests for Python 3.12+. Ref: ansible-collections#4656 * Fix setupSSLServer to work with Python 3.12.
…and no longer Fedora 38 (#7547) CI: devel supports Fedora 39, and no longer Fedora 38 (#7541) * devel supports Fedora 39, and no longer Fedora 38. * Disable 'mail' tests for Python 3.12+. Ref: #4656 * Fix setupSSLServer to work with Python 3.12. (cherry picked from commit b8ecb16) Co-authored-by: Felix Fontein <[email protected]> (cherry picked from commit 3ce83dc)
No activity for 2 years, I close the issue. |
It's not resolved, so it should be kept open until someone wants to work on this. |
Summary
The ansible_collections/community/general/tests/integration/targets/mail/files/smtpserver.py uses import asyncore whereas this module has been removed in Python 3.11, after being deprecated since Python 3.6.
One option is to copy Python 3.10 asyncore.py file in ansible test suite. Another is that someone should maintain an asyncore module on PyPI.
First, I reported the issue at ansible/ansible#76452 but I got rejected there.
Issue Type
Bug Report
Component Name
tests
Ansible Version
ansible-5.0.0 source code from PyPI.
Community.general Version
$ ansible-galaxy collection list community.general
Configuration
$ ansible-config dump --only-changed
OS / Environment
Any operating system.
Steps to Reproduce
Run the ansible integration test suite on Python 3.11: it emits a deprecation warning. The module will be removed from Python 3.12: see python/cpython#72719
Expected Results
ansible-5.0.0/ansible_collections/community/general/tests/integration/targets/mail/files/smtpserver.py must not fail.
Actual Results
I didn't try to run the Ansible test suite. I only noticed that "import asyncore" is used.
Code of Conduct
The text was updated successfully, but these errors were encountered: