1import os
2from pathlib import Path
3from dotenv import load_dotenv
4
5# Get the base directory
6basepath = Path()
7basedir = str(basepath.cwd())
8# Load the environment variables
9envars = basepath.cwd() / '.env'
10load_dotenv(envars)
11# Read an environment variable.
12SECRET_KEY = os.getenv('SECRET_KEY')
13