Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

OnExecutionUpdate() sometimes not called with OrderState.Filled

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    OnExecutionUpdate() sometimes not called with OrderState.Filled

    My strategy depends on knowing when an order is filled in OnExecutionUpdate(). Twice today with real Apex/Rithmic accounts, this failed to happen .OnExecutionUpdate was not called with OrderState.Filled. Is this a Rithmic issue? I've spent a lot of time working on this piece of software and it's not encouraging to realize that the sequence of events that are supposed to happen cannot be depended upon. There is no contingency, because obviously there is no way of knowing that OnEx was not called when it should have been.
    Last edited by gbourque; 06-04-2024, 12:39 PM.

    #2
    Hello gbourque,

    When using rithmic it is possible to see out of order events compared to other brokers, rithmic does not have a set order of events like most other brokers. As such we do recommend a specific way of developing strategies that use OnOrderUpdate or OnExecutionUpdate events

    Using the partial order quantity and accumulating a quantity is part of how the sample in the linked forum post works so that would be a correct approach.

    Because the events can happen out of order that can cause Order variables being used to have incorrect states when the OnOrderUpdate or OnExecutionUpdate is called which may cause conditions you use to not work as expected which may be a reason why your logic did not see that event. When working with rithmic and the order/execution events only the passed in values from the override can be used to control logic.

    I would suggest adding a general print at the top of each override so you can see the events that do happen just to confirm you observed the events in general. Beyond that you would need to review the sample in the forum post and make sure the logic you are using is built in a similar way.

    Comment


      #3
      Thanks. I do have print trace messages in the the event methods. That's how I knew OnEx was not being called. I'll check out the example and see it it helps.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      81 views
      1 like
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      42 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      64 views
      2 likes
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      66 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      54 views
      0 likes
      Last Post CarlTrading  
      Working...
      X