Who's there?
The spiritual successor to knockknock for PyTorch Lightning, to get a notification when your training is complete or when it crashes during the process with a single callback.
Features
- Supports E-Mail, Discord, Slack, Teams, Telegram
Installation
With pip:
python -m pip install whos-there
With uv:
uv add whos-there
With conda:
conda install conda-forge::whos-there
Check here for more information.
How to use it
import lightning.pytorch as pl
from whos_there.callback import NotificationCallback
from whos_there.senders.debug import DebugSender
trainer = pl.Trainer(
callbacks=[
NotificationCallback(senders=[
# Add your senders here
DebugSender(),
])
]
)
Requires your e-mail provider specific SMTP settings.
from whos_there.senders.email import EmailSender
# ...
EmailSender(
host="smtp.example.de",
port=587,
sender_email="from@example.com",
password="*********",
recipient_emails=[
"to1@example.com",
"to2@example.com",
]
)
Discord
Requires your Discord channel's webhook URL.
from whos_there.senders.discord import DiscordSender
# ...
DiscordSender(
webhook_url="https://discord.com/api/webhooks/XXXXXXXXXXXXXX/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
)
Slack
Requires your Slack room webhook URL and optionally your user id (if you want to tag yourself or someone else).
from whos_there.senders.slack import SlackSender
# ...
SlackSender(
webhook_url="https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX", # gitleaks:allow
channel="channel_name",
user_mentions=[
"XXXXXXXX"
]
)
Teams
Requires your Team Channel webhook URL.
from whos_there.senders.teams import TeamsSender
# ...
TeamsSender(
webhook_url="https://XXXXX.webhook.office.com/",
user_mentions=[
"twsl"
]
)
Telegram
You can also use Telegram Messenger to get notifications. You'll first have to create your own notification bot by following the three steps provided by Telegram here and save your API access TOKEN.
Telegram bots are shy and can't send the first message so you'll have to do the first step. By sending the first message, you'll be able to get the chat_id required (identification of your messaging room) by visiting https://api.telegram.org/bot<YourBOTToken>/getUpdates and get the int under the key message['chat']['id'].
from whos_there.senders.telegram import TelegramSender
# ...
TelegramSender(
chat_id=1234567890,
token="XXXXXXX:XXXXXXXXXXXXXXXXXXXXXXXXXXX"
)
Docs
uv run mkdocs build -f ./mkdocs.yml -d ./_build/
Conda
The conda repository is maintained here.
Update template
copier update --trust -A --vcs-ref=HEAD
Credits
This project was generated with
Big thanks to knockknock for the idea and code snippets.
Metadata
Release files for whos-there 0.6.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| whos_there-0.6.0.tar.gz | 9.7 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| whos_there-0.6.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 21.2 kB
Release files / whos_there-0.6.0.tar.gz
| Download URL | whos_there-0.6.0.tar.gz |
|---|---|
| Size | 9.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7c3ae541abd0e62c6494a221dc1f4645722f2199e78bc527a8312f4539788610
|
|
BLAKE2b-256 checksum How to use checksums |
33d96a8dd14040ffa70177bd19a825745dd38d13e35c46d4b11c6d638bc9015a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / whos_there-0.6.0-py3-none-any.whl
| Download URL | whos_there-0.6.0-py3-none-any.whl |
|---|---|
| Size | 11.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fcb43ce2520f1ee13b7bb7614d4a6ffff4ae4acc1cb24a77378f89c78fea5a3c
|
|
BLAKE2b-256 checksum How to use checksums |
4e70c4036c230c969788e3ebb535c29ef91d3e9a442481d0f53533e46f6b69c8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for whos-there 0.6.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.