Overview

This is a Python script that uses the Streamlit library to create a web-based Secret Santa generator. The script allows users to add participants, generate pairs, and send emails to participants with their Secret Santa assignments.

preview

Dependencies

Classes and Functions

Classes

Functions

Usage

  1. Run the script.
  2. Add participants either by uploading a CSV file or manually entering their names and email addresses.
  3. Click ‘Generate’ to generate the Secret Santa pairs.
  4. Click ‘Send Emails’ to send the emails to the participants.

SMTP Credentials

Add SMTP credentials in the send_email function.

Gmail SMTP Credentials:

App Password Generation (If 2-Step Verification is enabled):

  1. Go to your Google Account > Security > App Passwords.
  2. If not available, check if:
    • 2-Step Verification is set up for your account.
    • It’s only set up for security keys.
    • Your account is through work, school, or another organization.
    • Advanced Protection is turned on.
  3. Choose the app and device, then Generate.
  4. Follow instructions to enter the 16-character App Password.

Configuration and Security:

Disclaimer:

Note:

Learn More