Skip to content

fix(quick-trade): reconcile live closes and preserve account settings - #435

Merged
brokermr810 merged 147 commits into
mainfrom
test
Nov 30, 2026
Merged

brokermr810 merged 147 commits into
mainfrom
test

Conversation

@brokermr810

Copy link
Copy Markdown
Collaborator

Quick Trade could size a full close from a stale UI position and change exchange leverage or margin settings while loading account data. Full closes now use fresh venue positions, validate quantities and direction, and bound verified retries by both the unfilled request and current remaining position.

Balance reads and account warmup no longer configure leverage or margin mode. Explicit order configuration is revalidated instead of trusting historical success caches. OKX protective/algo orders are preserved by default for error 59669; legacy cancellation requires explicit opt-in. Position normalization and margin-mode handling are corrected across affected adapters. English and Chinese safety documentation is updated.

Validation: 108 focused backend regression tests passed. Companion desktop checks passed (99 focused tests, ESLint with no errors, production build); mobile checks passed (287 tests and production build). No live orders were submitted as part of these checks.

Deployment: no database migration required. Deploy API and trading workers with the companion desktop/mobile updates. Billing behavior is unchanged.

tianhe added 30 commits November 1, 2026 17:17
Signed-off-by: TIANHE <[email protected]>

# Conflicts:
#	backend_api_python/app/routes/community.py
buildwithpnj and others added 26 commits November 28, 2026 13:21
Signed-off-by: Prakash Jha <[email protected]>
(cherry picked from commit a5c7b82)
Signed-off-by: TIANHE <[email protected]>
Signed-off-by: TIANHE <[email protected]>

# Conflicts:
#	docs/trading/LIVE_TRADING_SAFETY.md
#	docs/trading/LIVE_TRADING_SAFETY_CN.md
Signed-off-by: TIANHE <[email protected]>

# Conflicts:
#	docs/trading/LIVE_TRADING_SAFETY.md
#	docs/trading/LIVE_TRADING_SAFETY_CN.md
@sonarqubecloud

Copy link
Copy Markdown

@codecov

codecov Bot commented Nov 30, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 11 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...d_api_python/app/services/quick_trade/positions.py 70.37% 4 Missing and 4 partials ⚠️
backend_api_python/app/routes/quick_trade.py 66.66% 2 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@brokermr810
brokermr810 merged commit 3c8c5b2 into main Nov 30, 2026
15 checks passed
MrRakun35 pushed a commit to MrRakun35/NovaTrade that referenced this pull request Dec 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants