mirror of
https://github.com/A6-9V/MQL5-Google-Onedrive.git
synced 2026-04-11 02:30:56 +00:00
This commit introduces several performance optimizations to the Flask web dashboard: 1. Consolidated file metadata checks in `MarkdownCache` using `os.stat()`. This reduces the number of system calls per request by retrieving both file existence and modification time in a single operation. 2. Extracted the large HTML template into a module-level constant `DASHBOARD_TEMPLATE`. This eliminates redundant memory allocations and string concatenations within the request lifecycle. 3. Pre-defined markdown file paths as constants to avoid repeated `os.path.join()` calls. 4. Simplified `render_template_string` calls by hardcoding static values (like the footer year). These changes reduce CPU overhead and latency for both the main dashboard and the health check endpoint. Verified via integration tests and Playwright screenshots. |
||
|---|---|---|
| .. | ||
| bolt.md | ||
| deploy.yml | ||