Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

scripts take long time to compile

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

    scripts take long time to compile

    Hi

    Compilation until yesterday on the same machine took around 3sec today i am almost 10. What might be the reason?

    #2
    Hello,

    Thank you for posting.

    I'm happy to check into this with you if you would please email us at PlatformSupport [AT] NinjaTrader [DOT] com. In your message please include a link to this forum thread and a copy of today's trace files. You will find these diagnostic files in the Documents > NinjaTrader 8 > Trace folder. I will need to review a copy of the files which are named 'trace.20170822.XXXXX.txt'. There will likely be multiple files for each day.

    Comment


      #3
      Still working fine for me. Maybe the problem is local.

      Comment


        #4
        looks like the problem came from some code i added recently on an AddOn OnStateChange for OnTerminated. So bottom line if you want to init or relase external resources thats not the place to do it as it gets called on every compilation. As an alternavie I use the OnWindowDestroyed,OnWindowCreated for ControlCenter window

        Comment


          #5
          Hello tolisss,

          Thank you for your response.

          Are you running the indicators or strategies that you are compiling? Are you reloading NinjaScript on the chart as well?

          The State OnTerminated should only be ran for the instance that is actually running. I recommend taking a look at the Lifecycle of NinjaScript objects page in our Help Guide: http://ninjatrader.com/support/helpG...fecycle_of.htm

          I would also make mention that each instance of the object that you compile and then reload is still held in memory and will not be released by .NET's garbage collection until you shut down NinjaTrader.

          Please let me know if you have any questions.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by argusthome, 03-08-2026, 10:06 AM
          0 responses
          62 views
          0 likes
          Last Post argusthome  
          Started by NabilKhattabi, 03-06-2026, 11:18 AM
          0 responses
          40 views
          0 likes
          Last Post NabilKhattabi  
          Started by Deep42, 03-06-2026, 12:28 AM
          0 responses
          21 views
          0 likes
          Last Post Deep42
          by Deep42
           
          Started by TheRealMorford, 03-05-2026, 06:15 PM
          0 responses
          23 views
          0 likes
          Last Post TheRealMorford  
          Started by Mindset, 02-28-2026, 06:16 AM
          0 responses
          51 views
          0 likes
          Last Post Mindset
          by Mindset
           
          Working...
          X