Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Cbi.MarketData.StartNow exception

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

    Cbi.MarketData.StartNow exception

    I have a simple strategy that enters on a limit and uses the SetProfitTarget and SetStopLoss functions. When running on the Sim101 account, the stragety works as expected. However, today I ran the strategy on a live account and although the entry order was sumitted and filled as expected, the stop loss and profit target orders were not submitted. In the log file immediately following the entry fill, there was the following message:

    9/28/2009 7:55:26 AM|3|4|Cbi.MarketData.StartNow: exception caught: Item has already been added. Key in dictionary: 'ESZ9' Key being added: 'ESZ9'

    Please does this exception mean? I am sure this is a clue as to why the stop loss and profit target orders were not sumbitted.

    #2
    trader20,

    Which brokerage technology are you using?
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      ZenFire at Mirus

      Comment


        #4
        trader20,

        Please attach your complete trace and log files with the time you placed the order. Thank you.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Here's the log file. (The brokerage account number is 'x' out for privacy). I didn't have TraceOrders set at the time this happened.
          Last edited by trader20; 09-29-2009, 06:47 AM.

          Comment


            #6
            You should still have trace logs that include information in My Documents\NinjaTrader 6.5\traces. Thank you.
            Josh P.NinjaTrader Customer Service

            Comment


              #7
              OK, here it is. The problem is at 7:55:26 when the entry order was filled. There should have been a stop and target order entered. I see an additional exception at 7:55:26:270 when the stop loss and profit target should have been entered.

              You can see an example of the same strategy working in the Sim101 account on ZN at 7:44:45:051. After the entry fill, you can see the stop and target get submitted as expected.
              Last edited by trader20; 09-29-2009, 06:47 AM.

              Comment


                #8
                Will get back to you after the investigation. Thank you for your patience on this matter.
                Josh P.NinjaTrader Customer Service

                Comment


                  #9
                  Ok. Thanks.

                  Comment


                    #10
                    I found something. In the trace log at 7:55:26:207 you can see the fill for instrument 'ES 12-09'. However, at 7:55:26:254 and thereafter, you can see references to instrument 'ES_DT 12-09'. ES_DT is a continuous contract that I created with the same parameters as the real 'ES'. Somehow, NT is getting confused between the two. I don't know why that would be happening, I certainly don't reference it in my strategy and there was no chart of ES_DT open.

                    I have deleted ES_DT in the instrument manager and I suspect that will fix the problem. However, I would like to recreate ES_DT for backtesting purposes. Maybe the problem was that when I created ES_DT, I set the Zen-Fire symbol map to 'ES', which is the same as the real ES instrument, so maybe that was confusing NT.

                    I will try running the strategy live tomorrow after having deleted ED_DT and report the result.

                    Comment


                      #11
                      That was the same conclusion development reached. Good luck.
                      Josh P.NinjaTrader Customer Service

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by judysamnt7, 03-13-2023, 09:11 AM
                      4 responses
                      53 views
                      0 likes
                      Last Post DynamicTest  
                      Started by ScottWalsh, Today, 06:52 PM
                      4 responses
                      33 views
                      0 likes
                      Last Post ScottWalsh  
                      Started by olisav57, Today, 07:39 PM
                      0 responses
                      5 views
                      0 likes
                      Last Post olisav57  
                      Started by trilliantrader, Today, 03:01 PM
                      2 responses
                      19 views
                      0 likes
                      Last Post helpwanted  
                      Started by cre8able, Today, 07:24 PM
                      0 responses
                      6 views
                      0 likes
                      Last Post cre8able  
                      Working...
                      X