Normalize fullwidth punctuation to ASCII across codebase.
Add scripts/normalize_ambiguous_unicode.py; fix corrupted patch_instance_theme_templates.py. Preserves curly quotes in string literals; removes Git homoglyph warnings on .env.example. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
"""预估盈亏比(前端 manual_order_rr_preview.js)公式与后端 calc_rr_ratio 口径一致。"""
|
||||
"""预估盈亏比(前端 manual_order_rr_preview.js)公式与后端 calc_rr_ratio 口径一致."""
|
||||
|
||||
|
||||
def _calc_rr(direction: str, entry: float, sl: float, tp: float):
|
||||
@@ -60,7 +60,7 @@ def _full_margin_risk_u(available: float, buffer: float, leverage: int, directio
|
||||
|
||||
|
||||
def test_full_margin_risk_short_hype():
|
||||
# 可用约 23.06U × 0.9 缓冲 × 5x,入场 62.5、止损 63.6
|
||||
# 可用约 23.06U × 0.9 缓冲 × 5x,入场 62.5,止损 63.6
|
||||
risk = _full_margin_risk_u(23.06, 0.9, 5, "short", 62.5, 63.6)
|
||||
assert risk is not None
|
||||
assert 1.5 <= risk <= 2.5
|
||||
|
||||
Reference in New Issue
Block a user