Config.py -

class Config: SECRET_KEY = "base-key" class ProductionConfig(Config): DEBUG = False Use code with caution. Copied to clipboard Best Practices for Your Config Working with Credentials and Configurations in Python

Depending on your project's complexity, there are several ways to structure this file: config.py

Using libraries like Pydantic Settings allows you to create a "Settings" class that automatically pulls from environment variables and validates data types. config.py