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
File details
Details for the file simple_email_sender-0.0.3.tar.gz
.
File metadata
- Download URL: simple_email_sender-0.0.3.tar.gz
- Upload date:
- Size: 3.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd6e7a66ae9c589bc4b4c5be41dae713c42c7f076919cc1b835bdc8716adf1e6 |
|
MD5 | 33fc689b7c2356ffbeb33d1c025e9d50 |
|
BLAKE2b-256 | d3081a916c27e9745b40d78d698f47fc8983bdb7e48171a1f945c8abbee8e72c |
File details
Details for the file simple_email_sender-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: simple_email_sender-0.0.3-py3-none-any.whl
- Upload date:
- Size: 3.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 426def1091a8009dd5440914c9044cd37aa17f3ef44c919592dca19294560996 |
|
MD5 | 65ad9b969aff7a6b7274de67573e79b3 |
|
BLAKE2b-256 | 1d82d03adb5f971ddff6855f7fa4d82f0b94f9566ea692308bb2200d83094e29 |