3 Commits
Author SHA1 Message Date
cbazzaandClaude Sonnet 4.6 c959a26dc0 fix: remaining medium-priority issues from code review + log analysis
trading_database.py:
- migrate_from_json: validate exit_time > entry_time before applying exit update
  Trades with exit before entry are logged as open (no invalid exit applied)
  This prevents the timestamp inversion bug that corrupted the DB with 625 bad trades

position_monitor.py:
- Replace fragile datetime.strptime('%Y-%m-%d %H:%M:%S') with fromisoformat()
  Handles both space-separated and ISO 8601 T-separated formats, strips microseconds

trading_bot_gui.py:
- Call infra.log_bot_status('running') on bot start -> bot_status table now populated
- Call infra.log_bot_status('stopped') on bot stop
  Previously bot_status table remained empty (0 rows), making monitoring impossible

telegram_bot_commands_old.py:
- Remove superseded file (replaced by telegram_bot_commands.py)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-12 12:20:32 +02:00
cbazza cbd6584db5 all changes done over the last 2 weeks 2025-12-16 22:02:15 +01:00
cbazzaandClaude 596718e30b feat: Trading Bot V1.8 - Aggressive Mode + Infrastructure
## Major Features
- Session Filter: NY-only trading (13:00-21:00 UTC)
- SQLite Database: Structured trade logging
- Telegram Bot: Real-time notifications (@Xausd_digger_bot)
- Streamlit Dashboard: Visual monitoring & analytics
- JSON Import: Historical data migration

## Infrastructure
- trading_database.py: SQLite trade storage
- telegram_notifier.py: Telegram integration
- infrastructure_patch.py: Combined DB + Telegram
- trading_dashboard.py: Real-time web dashboard
- import_json_to_db.py: JSON to SQLite migration

## Session Filter (V1.8 Aggressive Mode)
- session_filter_patch.py: Whitelist-based filter
- Blocks: Asian, London, Overlap sessions
- Active: NY session only (best performance: 47.6% WR)
- Base confidence: 60%

## Documentation
- V1.8_AGGRESSIVE_MODE_AKTIVIERT.md
- FIX_DUPLICATE_SCHEDULER.md
- DASHBOARD_WINDOWS_SERVER.md
- SQLITE_TELEGRAM_SETUP.md
- PROJECT_CLEANUP.md

## Cleanup
- Archived old V1.1-V1.7 versions
- Removed obsolete analysis scripts (replaced by dashboard)
- Added .gitignore for secrets and temp files

## Breaking Changes
- Requires telegram_config.json (use template)
- Requires Python packages: streamlit, plotly

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-26 21:14:01 +01:00