- Changed `check_authorized` in `scripts/telegram_deploy_bot.py` to fail closed (deny all) if `TELEGRAM_ALLOWED_USER_IDS` is unset or empty.
- Updated `scripts/TELEGRAM_BOT_SETUP.md` and `QUICK_DEPLOY.md` to document that `TELEGRAM_ALLOWED_USER_IDS` is now mandatory for bot access.
- Added Sentinel Journal entry in `.jules/sentinel.md` documenting the vulnerability and learning.
- Verified fix with reproduction script.
- Add `.btn:focus-visible` styles for better keyboard navigation visibility.
- Add `rel="noopener noreferrer"` and `aria-label` to external links for security and accessibility.
- Add `role="button"` to placeholder links (`href="#"`) for semantic correctness.
- Replace blocking `alert()` with a non-blocking button text change ("Coming Soon! 🚧") for better UX.
- Apply changes to both `index.html` and `dashboard/index.html`.
- Updated all references from Singapore 09 to Singapore 10 across documentation and scripts.
- Updated dates and timestamps to reflect the current migration date (February 4, 2026).
- Added migration details to VPS_SETUP_NOTES.md.
- Verified repository consistency and ran validation tests.
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>
- Updated `docs/NOTEBOOK_LM_CONTEXT.txt` with user-provided NotebookLM URL and context directives.
- Enhanced `scripts/market_research.py` and `scripts/upgrade_repo.py`:
- Added proper Jules integration using the REST API structure `{"model": ..., "prompt": ...}` to match MQL5 implementation.
- Added warning suppression for deprecated `google.generativeai` warnings.
- Added robustness checks for API keys.
- Enhanced `scripts/schedule_research.py` with file logging (`logs/scheduler.log`) and next-run prediction.
- Implements `CPositionManager` class in `ManagePositions.mqh` for robust Trailing Stop and Break Even logic.
- Updates `SMC_TrendBreakout_MTF_EA.mq5` to use `CPositionManager` and exposes Scalping inputs.
- Adds preset files for M5, M15, M30 scalping in `mt5/MQL5/Presets/`.
- Documents strategy parameters in `docs/SCALPING_STRATEGY.md`.
- Adds `scripts/research_scalping.py` utility.
- Added `scripts/setup_forge_runner.sh` for automated Gitea runner registration.
- Optimized `SMC_TrendBreakout_MTF.mq5` by replacing manual loops with native `ArrayMaximum`/`ArrayMinimum`.
- Optimized `SMC_TrendBreakout_MTF_EA.mq5`:
- Replaced `CopyTime` with `iTime` for faster bar checks.
- Replaced non-existent `iDonchian` handle with standard MQL5 price range logic using `CopyHigh`/`CopyLow`.
- Removed redundant code and handles in `OnInit`/`OnDeinit`.
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>
- Update `ZoloBridge.mqh` to support AES-256 encryption via `Zolo_Encrypt`.
- Add `ZoloEncryptionKey` input to `SMC_TrendBreakout_MTF_EA.mq5` and `EXNESS_GenX_Trader.mq5`.
- Pass encryption key to `SendSignalToBridge` function.
- Ensure backward compatibility (encryption is opt-in).
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>
- Moved `yfinance` and `pandas` imports inside `get_market_data`
- Moved `google.generativeai` import inside `analyze_with_gemini`
- Reduces startup time when these libraries are not immediately needed (e.g. missing API keys or dry runs)
- Keeps fallback simulation logic intact
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>
- Updated `scripts/market_research.py` to provide helpful hints on Jules NameResolutionError.
- Updated `docs/USER_NOTES.md` to document the schedule setup and current API status.
- Created `docs/upgrade_suggestions.md` to establish the upgrade context (NotebookLM) and track pending analysis.
- Verified scheduler execution (PID running).
- Note: Gemini API is currently rate-limited (429) and Jules API endpoint requires verification.
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>
Replaced per-branch git log calls with a single git for-each-ref command using the ahead-behind atom. This optimizes the script from O(N) to O(1) git subprocess calls.
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>
Replaced blocking `subprocess.run` calls with `asyncio.create_subprocess_exec` to ensure the Telegram bot event loop remains responsive during long-running deployment tasks.
Key changes:
- Switched to `asyncio.create_subprocess_exec` for command execution.
- implemented `asyncio.wait_for` to handle the 300s timeout.
- Added explicit process cleanup (kill/wait) on timeout.
- Manually decoded stdout/stderr since async subprocesses return bytes.
Verified with a reproduction script showing the event loop gap dropped from ~2.0s (blocking) to ~0.1s (non-blocking).
Co-authored-by: Mouy-leng <199350297+Mouy-leng@users.noreply.github.com>