Skip to content

guduchango/simple-python-design-patterns-and-solid-principle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

10 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Example Project: Design Patterns and SOLID Principles with Python and Stripe

This project is a practical example of using design patterns and SOLID principles in Python, integrating the Stripe API. The goal is to iteratively refactor the code, applying best practices while focusing on clean and maintainable design.


๐ŸŽฏ Project Goals

  • Demonstrate how to implement design patterns (Singleton, Factory, Strategy, etc.).
  • Apply SOLID principles (Single Responsibility, Open/Closed, Liskov Substitution, etc.).
  • Integrate a real API, like Stripe, to illustrate a practical use case.
  • Gradually improve the code design through refactoring.

๐Ÿš€ Technologies Used

  • Python 3.10+
  • Stripe API: For payment processing.
  • Virtual Environments: venv for dependency isolation.
  • Docker: More flexible

๐Ÿ› ๏ธ Setup and Installation

1. Clone this repository

git clone simple-python-design-patterns-and-solid-principle.git
cd simple-python-design-patterns-and-solid-principle.git

2. Set up the virtual environment

python -m venv venv
source venv/bin/activate   # Linux/Mac
venv\Scripts\activate  

3. Install dependencies

pip install -r app/requirements.txt

5. run

python3.10 src/main.py

About

Own python example: design patterns and solid principle

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages