How emy69/coomerdl works
Project Type and Purpose
• This is a standalone Python desktop application (“Coomer Downloader App”) with a GUI.
• Purpose: simplify and accelerate multithreaded downloads of images, videos, documents, and archives from a variety of “coomer”-style websites by pasting a URL into the UI.
a. Presentation Layer (GUI)
• app/ui.py
• app/about_window.py, settings_window.py, patch_notes.py
b. Application Logic (Controller / Orchestrator)
• main.py (entry point)
• app/progress_manager.py (manages download threads & progress updates)
• app/donors.py (optional credits display)
c. Download Engine & Plugins (Infrastructure)
• downloader/downloader.py (core download manager, task queue)
• downloader/*.py (site‐specific plugins: bunkr.py, erome.py, jpg5.py, simpcity.py)
d. Configuration & Resources
• resources/config/*.json, *.txt (languages, settings, patch notes)
• resources/img (logos, screenshot assets)
e. File System
• Local download folder (not coded but implied), settings file (“resources/config/settings.json”)
f. External Services (Third‐Party Sites)
• coomer.su, kemono.su, erome.com, bunkr-albums.io, simpcity.su, jpg5.su
Relationships & Data Flows
1. User clicks “Download” in the GUI.
2. UI layer calls ProgressManager (via main.py) to enqueue a download task.
3. ProgressManager dispatches tasks to downloader/downloader.py, which:
– Chooses the correct plugin module based on URL pattern.
– Spawns worker threads to fetch file lists & actual media in parallel.
4. Plugin module (e.g., erome.py) performs HTTP requests against the target site, parses HTML/json, and streams file data.
5. Downloaded files are written to disk (File System).
6. ProgressManager reports progress back to UI, which updates progress bars in app/ui.py.
7. Settings, translations, and patch notes are read from resources/config at startup or on‐demand.
Architectural Patterns & Principles
• MVC‐style separation:
• Model: download tasks & state (ProgressManager)
• View: tkinter/Qt‐based windows in app/ui.py
• Controller: main.py orchestrates interactions
• Plugin architecture: each “downloader” implements a common interface for URL parsing and file retrieval.
• Multithreading: thread pool in ProgressManager for concurrent downloads.
• Resource externalization: configs and language packs are stored in JSON/text under resources/config.
Essential Elements
• Component labels (e.g., “ProgressManager”, “Downloader Engine”, “Erome Plugin”)
• Config read events (on startup / settings change)