Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Is it a bug

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

    Is it a bug

    Hi,
    I'm working in NT6.5.18.
    I have a strategy that issues limit orders. If in Options>Strategies>NinjaScrip "Wait until flat..." is checked I get an order submited live immediately, but if its unchecked although I'm not in a historical trade the platform doesn't issue an order.
    Why???

    Baruch

    #2
    Hello,

    Thanks for your note.

    I am not aware of any bugs around this at this time.

    Can you please print out your Position.MarketPosition on every tick and make sure that your strategy is in a trade or not in a trade.at the time you start the strategy to verify this is the case.

    Then send me a screenshot of trying to start the strategy.

    Also, we hve released NinjaTrader 7 for download, may be worth downloading this as well unless you want to stick with 6.5.

    Let me know if I can be of further assistance.
    BrettNinjaTrader Product Management

    Comment


      #3
      Hi Bret,
      1. I know about NT7, and still I want to stay with 6.5
      2. The strategy is activated with COBC = true, so you don't need pics on every tick.
      I have pics for you but they are bigger than allowed on this forum, so give me an email where to sent.
      I don't understand what will it give you. Position tab is empty, Order tab is empty.
      I have a text on a chart from the strategy which says that my IOrder has value but this order isn't executed and after some bars its nullified.

      Baruch
      p.s.
      I'm not a beginner and it took me time to pin point a problem to you, so please treat it seriously

      Comment


        #4
        Hello,

        I treat every issue seriously. However we must first exhaust the simple things first before we get into if there is a bug here as 6.5 has been in production release for many years most bugs are out of the system at this time.

        I think I wasnt clear on what exactly I needed.

        I dont need a picture on each tick, what you need to do is on Each OnBarUpdate()

        Add in:

        Print(Time[0] + " Market Position is " + Position.MarketPosition.ToString());



        Then compare the OnBarUpdates with your the chart. I need a single picture of the output window and the chart.

        If you save the screenshot as a jpg when you save it with paint you will be able to post it to the forum.

        To send a screenshot press Alt + PRINT SCREEN to take a screen shot of the selected window. Then go to Start--> Accessories--> Paint, and press CRTL + V to paste the image. Lastly, save as a jpeg file and send the file as an attachment.


        Let me know if I can be of further assistance.
        BrettNinjaTrader Product Management

        Comment


          #5
          Hi Brett,
          I attach the picture. You can see on the chart bottomleft it shows entryOrder.Action and entryOrder.LimitPrice.
          As I said this order is not executed and after few bars the order is dead.

          Baruch
          Attached Files

          Comment


            #6
            Sorry,
            I didn't scroll all the way down in Output window.
            New pic.

            Baruch
            Attached Files

            Comment


              #7
              Hello,

              I needed to see the Strategies tab in the picture. Also under what condition is this run under for options.

              Wait until flat or Immediatly?

              Did you start the strategy before it went long? or after?


              I look forward to assisting you further.
              BrettNinjaTrader Product Management

              Comment


                #8
                Brett,
                This is exactly my point. You don't read what the problem is,
                Hi,
                I'm working in NT6.5.18.
                I have a strategy that issues limit orders. If in Options>Strategies>NinjaScrip "Wait until flat..." is checked I get an order submited live immediately, but if its unchecked although I'm not in a historical trade the platform doesn't issue an order.
                Why???

                Baruch
                you don't know what you want from me. First one screen then another.
                Do you want to solve the problem???

                Baruch
                p.s.
                Attached is the strategy tab
                Attached Files

                Comment


                  #9
                  Hello,

                  Thanks for posting the screenshot I needed.

                  As of currently in the Screenshot you supplied the strategy is in a green state on the strategies tab.

                  This lines up with the prints that I had you add to the strategy.

                  Also the strategy is green here indicating the Wait until flat condition is validated and the next trade the strategy submits will execute live.


                  Please add TraceOrders = True to Initialize for one more screenshot if you still believe there is still an issue here as I do not see any issue here with the supplied screenshots.


                  More then likely what you actually have going here is that your not continuing to call EnterLongLimit. If the EnterLongLimit does not fill by default before you stop calling it in OnBarUpdate the EnterLongLimit will cancel itself. This is what i feel you issue is currently based on what you have shown me.

                  Please read the following on this order type, an easy way to test is to replace this with EnterLong().



                  Order Submission for Entry and Exit Methods - Basic Operation
                  You can submit and manage orders in one of two ways:

                  • <LI class=rvps1>Orders that automatically expire (cancel) at the end of a bar unless re-submitted
                  • Orders that are live until you purposely cancel them
                  BrettNinjaTrader Product Management

                  Comment


                    #10
                    Hi,
                    No this is not the case.
                    The order is not executed even when IOrder has value!!
                    I do call it on every bar!

                    Baruch

                    p.s.
                    Attached the trace.

                    Comment


                      #11
                      Hello,

                      There was no attached trace.

                      The last step in troubleshooting your strategy is to add TraceOrder = True to the initialize and also to add in another print for when your Entry Condition is called, then run the strategy again live and send me another screenshot of the OutPut window. What we would need to see if the strategy state green in the strategies tab, we would need to see the position be flat.

                      Then after the position is flat we would need to see the call to your entry condition print then finally the TraceOrders will output the status of the order.

                      This would either A. Prove your point and in this case I would need you to send in your strategy so that I may test it on my side, or B. Show you where the logic issue is in your strategy and where the disconnect is.

                      Thank You.
                      BrettNinjaTrader Product Management

                      Comment


                        #12
                        Here are the trace and the screenshot

                        Baruch
                        Attached Files

                        Comment


                          #13
                          Hello,

                          Ok we see the error here, looks like your calling EnterLongLimit() twice in the same onbarupdate().

                          or your calling it a second time with KeepOrderActive = True.

                          Please either send your strategy to support at ninjatrader dot com attn: Brett reference this forum post or check your strategy for where you could called this twice or post your entry logic here for me to look into.

                          Also, this error that you posted indicates something already submitted, please post the entire log output so we can see where it was originally submitted at as you didnt include enough lines for me to see the original order that was accepted.
                          BrettNinjaTrader Product Management

                          Comment


                            #14
                            Thank you very much for your support.
                            You find endless amount of errors in my coding without even looking in it.
                            Still its NT BUG.
                            Attached is a strategy that show it.
                            To see the bug in options should be "Wait until flat.." checked and you need that an EMA be away of price. Then the strategy issues a limit order at EMA price. This order is not executed! If starting live you are in position just stop the strategy and start it with different EMA period. The second parameter "ShowBug" if you change to false then the strategy will execute the limit order. Its magic!
                            Now please answer what is it:
                            a. BUG
                            b. feature

                            Baruch
                            p.s.
                            In your first reply you suggested me to move to NT7. I can inform you that I tried it and surprise surprise there is a bug that I can't work around.
                            If you're asking, I did report it but you probably know what a response I get.
                            Because this bug will hurt all of NT consultants and because its such a pleasure to resolve it with NT support, I leave it to another poor soul.
                            Attached Files

                            Comment


                              #15
                              Bug

                              I think I have this same issue. I look forward to seeing if it can be resolved.

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                              0 responses
                              639 views
                              0 likes
                              Last Post Geovanny Suaza  
                              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                              0 responses
                              366 views
                              1 like
                              Last Post Geovanny Suaza  
                              Started by Mindset, 02-09-2026, 11:44 AM
                              0 responses
                              107 views
                              0 likes
                              Last Post Mindset
                              by Mindset
                               
                              Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                              0 responses
                              569 views
                              1 like
                              Last Post Geovanny Suaza  
                              Started by RFrosty, 01-28-2026, 06:49 PM
                              0 responses
                              572 views
                              1 like
                              Last Post RFrosty
                              by RFrosty
                               
                              Working...
                              X