This package provides a simple notifier sending emails
Project description
This package provides a simple notifier sending emails.
Free software: GNU General Public License v3
Copyright (c) 2021 Henning Janssen
Installation
To install the package, simply run within your terminal:
$ pip install simple_email_sender
Usage
You will need only one single line, to trigger a message within your Python code:
sender.info("Hello World")
For a fully working example, you need to specify the server_settings in a separate file
# server_settings.yaml
# Use this file to store the server setting for the SMTP-Server
"name": "example@email.com"
"password": "MySecretPassword"
"server": "smtp.example.com"
"port": 465
And this is a MWE:
# example.py
from simple_email_sender import Sender
# Before running this example, you need to change your settings in the
# 'server_settings.yaml'-file according to your personal needs
def main():
receiver = "example@email.com"
sender = Sender("./server_settings.yaml", receiver, subject="Experiment 123")
sender.info("Hello World")
sender.error("Something unexpected happened and you should take care of it...")
if __name__ == "__main__":
main()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for simple_email_sender-0.0.2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1efb86bbc7d4c430661f4e97690aa9d8dd90953b5c4fef022ce3bd775cb7545a |
|
MD5 | c28a064f7530dfe1848f2f1b93ad9bc8 |
|
BLAKE2b-256 | 4d5a1940762176b00ff63b1e1c41f513d67b30349d18d457cd0272f61ff56900 |
Close
Hashes for simple_email_sender-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cdea3efba97058bbb19cd44077178a2b458a46506aeaa31d92c79bb033510f36 |
|
MD5 | b6c0900b4882fb00c5bd0cc6bd5c8c6d |
|
BLAKE2b-256 | f52903d0c28ff95c76430102cd8ca8f3862a0170c3a203952e0f0cb7c211cdde |