Install & Compatibility
Where this runs
tested against v0.1.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.920 runs
installs and imports cleanly · install 0.0s · import 1.128s · 37.6MB
glibcpy 3.10–3.920 runs
installs and imports cleanly · install 3.6s · import 1.015s · 39MB
36MB installed
● package 36MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
EmailServer
✓ from email_to import EmailServer
✗ import email_to
Message
✓ from email_to import Message
✗ import email_to
This quickstart demonstrates how to initialize an `EmailServer` and send a basic HTML email using `quick_email`. It's crucial to use environment variables for sensitive SMTP credentials rather than hardcoding them.
import email_to
import os
# It's recommended to use environment variables for sensitive credentials
SMTP_HOST = os.environ.get('EMAIL_SMTP_HOST', 'smtp.example.com')
SMTP_PORT = int(os.environ.get('EMAIL_SMTP_PORT', 587))
SMTP_USERNAME = os.environ.get('EMAIL_USERNAME', 'your_email@example.com')
SMTP_PASSWORD = os.environ.get('EMAIL_PASSWORD', 'your_app_password')
RECIPIENT_EMAIL = os.environ.get('EMAIL_RECIPIENT', 'recipient@example.com')
try:
# Initialize the EmailServer
server = email_to.EmailServer(
SMTP_HOST,
SMTP_PORT,
SMTP_USERNAME,
SMTP_PASSWORD
)
# Send a quick HTML email
server.quick_email(
RECIPIENT_EMAIL,
'Test Subject from email-to',
['<h1>Hello from email-to!</h1>', '<p>This is a test HTML email.</p>'],
style='h1 { color: blue; } p { font-family: sans-serif; }'
)
print("Email sent successfully!")
except Exception as e:
print(f"Failed to send email: {e}")
Debug
Known issues
breakingThe library has not been updated since October 2017, indicating it is abandoned. It may not be compatible with modern Python versions (e.g., Python 3.8+) or current email security standards (e.g., TLS 1.3).fixConsider using more actively maintained libraries like `python-emails`, `yagmail`, or directly using Python's `smtplib` and `email` modules which are part of the standard library and continuously updated.
affects: 0.1.0 and likely all prior versions
gotchaThe original quickstart examples on PyPI show hardcoding SMTP usernames and passwords directly into the code. This is a significant security vulnerability.fixAlways use environment variables (e.g., `os.environ.get()`) or a secure configuration management system to store and access sensitive credentials.
affects: 0.1.0
gotchaDue to its age, 'email-to' might not support the latest authentication mechanisms or TLS protocols required by modern SMTP servers, potentially leading to connection failures or insecure communications.fixVerify compatibility with your specific SMTP server's requirements. If issues arise, a more modern library or direct `smtplib` usage would be a safer alternative.
affects: 0.1.0
Upgrade
Version history
0.1.0latest on PyPI · released Oct 1, 2017
Audit
Dependencies
No dependency data recorded yet.