Skip to content

Preserve final-bar sell signal until next market open #6

Description

@andywkff

Problem

When an exit rule fires on the final input bar, the core returns .exit but also synthesizes a completed trade at that bar's close. This contradicts next-market-open execution semantics.

Acceptance criteria

  • Final-bar exit remains pending and emits no completed trade for that position.
  • Adding the next bar completes the trade at the next bar's open.
  • Existing open-position finalization behavior without a pending exit remains unchanged.
  • Targeted and full Swift tests pass.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions