Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

OnOrderUpdate called twice with same order filled information

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

    OnOrderUpdate called twice with same order filled information

    Hi,

    Last week, during a time of high volume, the strategy received twice a message (OnOrderUpdate) saying that the order had been filled. It was exactly the same order. I had never see before and I wondering how can I avoid this problem. My strategy computes internally its position and this causes problems.
    See an extract of the corresponding log file below. The order in question is called O_CortoST. In red I highlighted the problem.

    Code:
    2021-06-16 10:59:59:374|1|16|NinjaScript strategy 'UBSTv112paramState/235080936' submitting order
    2021-06-16 10:59:59:389|1|32|Order='fc03dddab6c74f9eacc0ebb19 a6635d7/K7462' Name='O_CortoST' New state='Submitted' Instrument='MES 06-21' Action='Sell' Limit price=4221 Stop price=4221 Quantity=1 Type='Stop Market' Time in force=DAY Oco='235080936_OCO_CortoRR_20210616010402_18_1' Filled=0 Fill price=0 Error='No error' Native error=''
    2021-06-16 10:59:59:462|1|32|Order='1254002464/XXXX' Name='O_CortoST' New state='Accepted' Instrument='MES 06-21' Action='Sell' Limit price=0 Stop price=4221 Quantity=1 Type='Stop Market' Time in force=DAY Oco='235080936_OCO_CortoRR_20210616010402_18_1' Filled=0 Fill price=0 Error='No error' Native error=''
    2021-06-16 10:59:59:462|1|32|Order='1254002464/XXXX' Name='O_CortoST' New state='Working' Instrument='MES 06-21' Action='Sell' Limit price=0 Stop price=4221 Quantity=1 Type='Stop Market' Time in force=DAY Oco='235080936_OCO_CortoRR_20210616010402_18_1' Filled=0 Fill price=0 Error='No error' Native error=''
    2021-06-16 10:59:59:618|1|8|Execution='464381393408' Instrument='MES 06-21' Account='K7462' Exchange=Globex Price=4230 Quantity=1 Market position=Short Operation=Operation_Add Order='1254060868' Time='6/16/2021 11:00 AM'
    2021-06-16 10:59:59:653|1|32|Order='1253281275/XXXX' Name='O_CortoRR' New state='Filled' Instrument='MES 06-21' Action='Sell' Limit price=4230 Stop price=0 Quantity=1 Type='Limit' Time in force=DAY Oco='235080936_OCO_CortoRR_20210616010402_18_1' Filled=1 Fill price=4230 Error='No error' Native error=''
    2021-06-16 10:59:59:657|1|8|Execution='464381394176' Instrument='MES 06-21' Account='K7462' Exchange=Globex Price=4230 Quantity=1 Market position=Short Operation=Operation_Add Order='1253281275' Time='6/16/2021 11:00 AM'
    [COLOR=#e74c3c]2021-06-16 10:59:59:675|1|32|Order='1254002464/XXXX' Name='O_CortoST' New state='Filled' Instrument='MES 06-21' Action='Sell' Limit price=0 Stop price=4221 Quantity=1 Type='Stop Market' Time in force=DAY Oco='235080936_OCO_CortoRR_20210616010402_18_1' Filled=1 Fill price=4221 Error='No error' Native error=''[/COLOR]
    2021-06-16 10:59:59:682|1|16|NinjaScript strategy 'UBSTv112paramState/235080936' submitting order
    [COLOR=#e74c3c]2021-06-16 10:59:59:694|1|32|Order='1254002464/XXXX' Name='O_CortoST' New state='Filled' Instrument='MES 06-21' Action='Sell' Limit price=0 Stop price=4221 Quantity=1 Type='Stop Market' Time in force=DAY Oco='235080936_OCO_CortoRR_20210616010402_18_1' Filled=1 Fill price=4221 Error='No error' Native error=''[/COLOR]

    #2
    Hello Aquatrade,

    Please send an email to scriptingsupport [at] ninjatrader [dot] com so that we may further investigate.

    In the email please include a link to this forum thread.
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by GwFutures1988, Today, 02:48 PM
    1 response
    5 views
    0 likes
    Last Post NinjaTrader_Clayton  
    Started by ScottWalsh, 04-16-2024, 04:29 PM
    6 responses
    32 views
    0 likes
    Last Post ScottWalsh  
    Started by frankthearm, Today, 09:08 AM
    10 responses
    36 views
    0 likes
    Last Post frankthearm  
    Started by mmenigma, Today, 02:22 PM
    1 response
    4 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Started by NRITV, Today, 01:15 PM
    2 responses
    10 views
    0 likes
    Last Post NRITV
    by NRITV
     
    Working...
    X