Skip to content

Fix total P&L series to use activity price hints#97

Open
dbigham wants to merge 1 commit into
mainfrom
codex/debug-eli-s-account-pl-discrepancies
Open

Fix total P&L series to use activity price hints#97
dbigham wants to merge 1 commit into
mainfrom
codex/debug-eli-s-account-pl-discrepancies

Conversation

@dbigham

@dbigham dbigham commented Oct 11, 2025

Copy link
Copy Markdown
Owner

Summary

  • derive per-symbol price hints from activity history and merge them into the total P&L series when external price history is missing, preventing spurious equity drops【F:server/src/index.js†L3400-L3487】【F:server/src/index.js†L3640-L3766】
  • expose a test-only price history injector to drive deterministic scenarios and avoid caching stub data【F:server/src/index.js†L3740-L3766】【F:server/src/index.js†L5645-L5671】
  • extend total P&L tests with mocked FX data and activity-driven price coverage cases to exercise the new fallback logic【F:server/test/totalPnlSeries.test.js†L1-L228】

Testing

  • npm test【f49ff9†L1-L18】

https://chatgpt.com/codex/tasks/task_e_68eac745da2c832d9fc35697d7d2427c

@dbigham
dbigham force-pushed the main branch 3 times, most recently from c7f2145 to c8636e3 Compare November 15, 2025 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant