Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy technical problems with GC but not with CL

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

    Strategy technical problems with GC but not with CL

    Hi,
    I have problems using a strategy which works on CL (oil) but not on GC (gold). SL and TP are set on CL but not on GC using the same strategy script. I didn't develope the script, I am just a user, but the strange thing is, that the strategy creates a SL and TP order, but on GC it doesn't. Nobody of our community has the same issue using these strategies, only me. The differences are: I am in Germany and we are using "," instead of "." in numbers like 2024,1 for gold prices ot 80,23 for a Oil price in futures.
    The developer of the strategy does also have no idea anymore.
    Any ideas?

    #2
    Hello theotusch,

    Thank you for your post.

    This would require debugging the strategy using prints and TraceOrders. If the developer would like assistance debugging the strategy, he can reach out to us here on the forum or at scriptingsupport[at]ninjatrader.com

    If you have experience coding and would like to debug the strategy yourself, we can assist in that process.

    Comment


      #3
      Hi, perhaps I can provide a log file first and a screenshot. Can I debug a strategy, where I can't see the code?
      Click image for larger version  Name:	image.png Views:	0 Size:	36.6 KB ID:	1298971Click image for larger version  Name:	image.png Views:	0 Size:	75.6 KB ID:	1298972​Logfile:
      [Redacted]
      As I said, using this strategy in CL, it is working perfectly.
      The SL shoud be arround 2369 and the TP 2375, but they do not appear. Instead the orders are done it less than 1s, see first screenshot arround 15:26:52 (UTC+2) Berlin.
      Hope you can give me a hint.
      best regards,
      theo

      Comment


        #4
        Hello theo,

        We removed the log file from your post as this can contain sensitive user information. In the future, send these by email to support[at]ninjatrader.com.

        However, for this issue, the log would not provide helpful information unfortunately. The output from prints and TraceOrders will tell us why conditions are evaluating as true or false, and why orders are being submitted, ignored, or cancelled.

        You will not be able to debug this script yourself using prints and TraceOrders if you don't have access to the code. The developer/vendor of the script would need to debug the strategy, so you will need to reach out to them for assistance. ​

        Comment


          #5
          Additional information for this case. I slowed down in playback mode (1x) and retrieved this messages from the strategy:
          Click image for larger version

Name:	image.png
Views:	77
Size:	92.6 KB
ID:	1298997

          Comment


            #6
            I retrieved some code lines for the execution of the order:
            ​​in the U.S. this works for CL and GC
            On my computer in Germany this works in CL, but not in GC. This is crazy. Please have a look at it, what could cause this strange behavior. I also can add the log file from the playback of today....
            Last edited by NinjaTrader_Gaby; 04-09-2024, 10:12 AM.

            Comment


              #7
              Hello theotusch,

              Please refrain from posting your log files because these contain sensitive user info.

              As previously mentioned, you will need the entire script in order to debug it using prints and TraceOrders. Without the information from prints and TraceOrders we are not able to make assessment on what could be going on with the code.

              Tests from Playback without the debugging info will not provide sufficient information. These errors need to be fixed from within the strategy's code, and to determine where in the code the errors are coming from would also require debugging.

              The developer/vendor of the script would need to debug the strategy, so you will need to reach out to them for assistance. ​
              Last edited by NinjaTrader_Gaby; 04-09-2024, 10:15 AM.

              Comment


                #8
                The code is not availabe, because its licenced. I reset the topstep combine and therefore I had to restart the programs. Now I have the same issue on CL. The strategy wants to place an order of "0" which is not possible. I would like to use this strategy, but it does not run on my computer.

                Comment


                  #9
                  You will need to reach out to the developer of the script for assistance. We are not able to assist in debugging third party scripts.

                  Please let us know if you have any further questions.

                  Comment


                    #10
                    NinjaTrader_Gaby​ I am the developer of the strategy. I can understand you wanting to troubleshoot using the print & TraceOrders statements but I don't believe there is anything wrong in the script, there are literally hundreds of people running that script without issue. Also, yesterday he had failed his Topstep eval and did a reset, after the reset, he started having the same issue with CL which until then was working fine. I have no way to reproduce the errors on any of my computers, so I can't really work with you on a resolution and if I release the source code to him, then all my safeguards are gone. I am wondering if it's something related to a Windows or NinjaTrader configuration since it's a German region/language, but I am at a complete loss.

                    Comment


                      #11
                      Hello mlarocco,

                      Thank you for your post.

                      If the stop loss and take profit orders are not being submitted as the user originally posted, this would indicate that the condition to place the order is not evaluating as true and the order is not being submitted, or the order is being ignored for other reasons, or the order is being cancelled. The OCO ID error suggests the OCO ID is being reused - if this is an Unmanaged script, you can generate a new OCO ID using GetAtmStrategyUniqueId().



                      Debugging using Prints and TraceOrders would be necessary to analyze and understand why the script is not submitting orders as expected. If you are willing, you could give the client a protected assembly version of the script with prints and TraceOrders they can run on their PC and provide the output to you for analysis.

                      Unfortunately, without the output from Prints or TraceOrders there is not much our team can offer in the way of support as we don't have any information to go off of.

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by NullPointStrategies, Yesterday, 05:17 AM
                      0 responses
                      65 views
                      0 likes
                      Last Post NullPointStrategies  
                      Started by argusthome, 03-08-2026, 10:06 AM
                      0 responses
                      139 views
                      0 likes
                      Last Post argusthome  
                      Started by NabilKhattabi, 03-06-2026, 11:18 AM
                      0 responses
                      75 views
                      0 likes
                      Last Post NabilKhattabi  
                      Started by Deep42, 03-06-2026, 12:28 AM
                      0 responses
                      45 views
                      0 likes
                      Last Post Deep42
                      by Deep42
                       
                      Started by TheRealMorford, 03-05-2026, 06:15 PM
                      0 responses
                      50 views
                      0 likes
                      Last Post TheRealMorford  
                      Working...
                      X