Commit Graph
10 Commits
Author SHA1 Message Date
jackyu66gitandClaude Opus 4.6 73dac50a36 chore: 清理git跟踪的node_modules + 添加node_modules/.DS_Store到gitignore
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-06 13:29:36 +08:00
jackyu66git d01a261828 fix: 删除零成交误判逻辑 + 各种稳定性修复
- 删除: Bitget GetTradeFee 零成交检查(PlaceMarketOrder 成功即成交)
- 修复: GetTradeFee 加 1s 延迟 + 查不到返回 0(用配置估算费兜底)
- 修复: HL InitExchange 在 NewTrader 中提前调用,避免 szDecimals 延迟
- 修复: close_failed 30 次重试上限,超限标记 failed 并清理
- 修复: DB 恢复时校验 Legs 完整性,跳过非法记录
- 修复: checkScaleIn/checkExit nil guard 防 panic
- 修复: config.go 参数调整(手续费、阈值等)
- 移除: scanner.go 中 MEW/USTC 等低流动性币对
- 添加: 更详细的下单日志(szStr、amountUSD、price)
- 添加: bin/ 到 .gitignore
2026-05-05 00:41:39 +08:00
jackyu66git 0b2bfd0b02 chore: remove re-tracked gitignored files 2026-05-04 18:27:44 +08:00
jackyu66git 49da6fd35b fix: HL balance now reads spot USDC via SpotUserState
HL testnet USDC lives in the spot account, not the perp clearinghouse.
GetBalance() was calling UserState() (perp clearinghouseState), which
returned /usr/bin/bash. Switched to SpotUserState() and parse USDC.total - USDC.hold.

Also cleaned up .gitignore to exclude .env, binary, logs, data/.
2026-05-04 17:48:14 +08:00
jackyu66git 24727e4ec4 refactor: HL EVM signing via sonirico/go-hyperliquid SDK 2026-05-04 16:16:21 +08:00
jackyu66git e5ea78ffd2 feat: real trading mode, auto-stop after 5 trades, HL testnet support
- config.json: test_mode=false, ready for sim/testnet trading
- trader.go: auto-stop after 5 real trades, exchange response logging,
  Stop()/Start() API, shuttingDown flag for graceful stop
- dashboard.go: POST /api/stop + POST /api/start endpoints,
  trading status in SSE stats
- exchange/hyperliquid.go: switch HL WS to testnet endpoint
- exchange/hyperliquid_trade.go: switch REST to testnet endpoint,
  support base64 + 32-byte EVM private keys
- main.go: listen on trader.StopCh (graceful, no process exit)
- scanner.go: trim TrackedCoins to only 6 core coins (DOGE/LINK/ONDO/OP/WIF/ARB)
- .gitignore: ignore main binary
2026-05-04 14:31:52 +08:00
jackyu66git 0288dc8284 feat: 手续费改为逐笔USD累算 + Vite React前端 + system_orders表 + README 2026-05-04 04:34:27 +08:00
jackyu66git 51b8ee0c8a chore: 添加.gitignore, 移除日志文件跟踪 2026-05-04 01:51:17 +08:00
jackyu66git 0c1eaedcb6 Fix: remove DB from git tracking, add to gitignore 2026-05-03 17:28:30 +08:00
jackyu66git 719f0a061d Initial commit 2026-05-03 16:54:36 +08:00