• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

What am I doing wrong?

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

  • koganam
    replied
    Originally posted by ETFVoyageur View Post
    Brett,

    Thank you for your help. You got me thinking along the right lines. The solution turns out to be to check Debug | Options | Debugging | General | Enable Just My Code. That silences all of the exceptions chatter. NT now just comes up cleanly and exits cleanly (as far as anything I get to see).

    Is there any drawback to "Enable Just My Code" that you or koganam or anyone else sees?

    --EV
    There could be, but then you would just turn back on the options to see everything again. ,NET uses a lot of internal "try...catch, but only log and continue" blocks. Those are what you are seeing. Pretty much the same that we have to do when we try to query all properties of an object, as any indexed properties trigger exceptions in GetValue(<object>, index). unless we already know the index, as most of us just use GetValue(<object>, null) routinely, because most of the properties will not be indexed anyway.
    Last edited by koganam; 09-06-2016, 08:51 PM.

    Leave a comment:


  • NinjaTrader_Brett
    replied
    Na and in fact likely would recommend it. Glad we were able to get down to the bottom. I'll know for next time we have someone run into it so appreciate you updating the thread.

    -Brett

    Leave a comment:


  • ETFVoyageur
    replied
    Brett,

    Thank you for your help. You got me thinking along the right lines. The solution turns out to be to check Debug | Options | Debugging | General | Enable Just My Code. That silences all of the exceptions chatter. NT now just comes up cleanly and exits cleanly (as far as anything I get to see).

    Is there any drawback to "Enable Just My Code" that you or koganam or anyone else sees?

    --EV

    Leave a comment:


  • NinjaTrader_Brett
    replied
    Understand. The thread abort exception you can disregard. Largely expected on shutdown. Some exceptions are expected and handled appropriately. Unhandled exceptions are never expected however and we always trace that to the trace file. Which leads me to believe nothing is actually going wrong in NT.

    I feel like you have visual studio settings to break on more exceptions then needed, perhaps too sensitive. Might try going into the Debug > Windows > Exceptions window and disable all exceptions. Does it change anything for you? Since you for sure can customize what exceptions you want visual studio to pick up on or disregard. I still feel all things point to visual studio settings. Which would cause problem across any c# app not just if its from the .zip or the visual studio feature in NinjaScript editor.

    Out of ideas other then that for now. Might still be worth trying a reset of visual studio settings along the idea above.

    Leave a comment:


  • ETFVoyageur
    replied
    Just so there is no misunderstanding -- I am still seeing the File Not Found exceptions. I did not mention them in the last few posts because VS does not break on them -- they just show up in the output window. The same ones occur regardless of how NT is started.

    --EV

    Leave a comment:


  • ETFVoyageur
    replied
    Originally posted by NinjaTrader_Brett View Post
    Its almost got to be some settings in visual studio I feel. Since it only has issue when started from there.
    That's not correct. To be entirely clear, here is what happens:

    On the way up -- if NT is launched manually, nothing is detected. That's because these exceptions are not logged / traced, and VS cannot yet be attached. If started from VS an exception is caught, but there is no reason to believe it is not also there in the manual case, just undetected.

    Starting from the same point -- NT is up and VS is attached -- the exceptions seen are identical, It does not matter whether NT was launched manually and VS launched from NT, or whether VS was launched manually and used to start NT. Either way the same exceptions are seen.

    To summarize the exceptions that VS breaks on -- there are two of them. The first happens on the way up and is detectable only if VS is already attached (i.e. NT is launched from VS)
    Code:
    An exception of type 'System.ArgumentException' occurred in mscorlib.dll and wasn't handled before a managed/native boundary
    
    Additional information: Requested value 'Replay' was not found.
    If I "OK" it, so I wind up in a break state, the stack is
    Code:
         mscorlib.dll!System.Enum.EnumResult.SetFailure(System.Enum.ParseFailureKind failure, string failureMessageID, object failureMessageFormatArgument)    Unknown
         mscorlib.dll!System.Enum.TryParseEnum(System.Type enumType, string value, bool ignoreCase, ref System.Enum.EnumResult parseResult)    Unknown
         mscorlib.dll!System.Enum.Parse(System.Type enumType, string value, bool ignoreCase)    Unknown
         [Native to Managed Transition]    
         [Managed to Native Transition]    
         NinjaTrader.VMRuntime.dll!lbU=.abc=.hrc=(ref object h7c=, object[] iLc=, bool ibc=, System.Reflection.MethodBase irc=, bool i7c=)    Unknown
         NinjaTrader.VMRuntime.dll!lbU=.wLo=.xLo=(lbU=.Arc= value)    Unknown
    >    NinjaTrader.VMRuntime.dll!lbU=.yrY=.z7Y=(lbU=.Arc= 0LY=)    Unknown
         NinjaTrader.VMRuntime.dll!VMRuntime.Libraries.CSVMRuntime.QrY=(lbU=.tbY= Q7Y=, lbU=.Arc= RLY=)    Unknown
         NinjaTrader.VMRuntime.dll!VMRuntime.Libraries.CSVMRuntime.PrY=(System.Reflection.Assembly P7Y=, string QLY=, object[] QbY=)    Unknown
         NinjaTrader.VMRuntime.dll!VMRuntime.Libraries.CSVMRuntime.RunMethod(string PQYB, object[] PgYB)    Unknown
         NinjaTrader.Core.dll!NinjaTrader.Cbi.LicenseData.LicensedProviders.set(NinjaTrader.Cbi.Provider[] value)    Unknown
         Microsoft.GeneratedCode!Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderLicenseData.Read5_LicenseData(bool isNullable, bool checkType)    Unknown
         Microsoft.GeneratedCode!Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderLicenseData.Read6_LicenseData()    Unknown
         [Native to Managed Transition]    
         [Managed to Native Transition]    
         System.Xml.dll!System.Xml.Serialization.TempAssembly.InvokeReader(System.Xml.Serialization.XmlMapping mapping, System.Xml.XmlReader xmlReader, System.Xml.Serialization.XmlDeserializationEvents events, string encodingStyle)    Unknown
         System.Xml.dll!System.Xml.Serialization.XmlSerializer.Deserialize(System.Xml.XmlReader xmlReader, string encodingStyle, System.Xml.Serialization.XmlDeserializationEvents events)    Unknown
         System.Xml.dll!System.Xml.Serialization.XmlSerializer.Deserialize(System.Xml.XmlReader xmlReader)    Unknown
         NinjaTrader.Core.dll!NinjaTrader.Cbi.License.Verify(System.Action<string, NinjaTrader.Cbi.InvalidCode, bool> errorCallback)    Unknown
         NinjaTrader.exe!NinjaTrader.AppHelper.OnStartup.AnonymousMethod__0(object o)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()    Unknown
         mscorlib.dll!System.Threading.ThreadPoolWorkQueue.Dispatch()    Unknown
    When continuing, NT comes up.

    =====

    The second exception type happens on exit. This happens regardless of how NT and VS were started. Starting either one manually, and then the other one from the manually-started one, produces multiple of the following on exit
    Code:
    An exception of type 'System.Threading.ThreadAbortException' occurred in System.dll and wasn't handled before a managed/native boundary
    
    Additional information: Thread was being aborted.
    The stack for the first one is
    Code:
    >    ActiproSoftware.Text.Addons.DotNet.Wpf.dll!#H.#G.#eg(int #Dvf)    Unknown
         ActiproSoftware.Text.Addons.DotNet.Wpf.dll!ActiproSoftware.Text.Languages.CSharp.Implementation.CSharpLexer.#xCc(ActiproSoftware.Text.ITextBufferReader #o6b, char #cvf)    Unknown
         ActiproSoftware.Text.Addons.DotNet.Wpf.dll!ActiproSoftware.Text.Languages.CSharp.Implementation.CSharpLexer.GetNextToken(ActiproSoftware.Text.ITextBufferReader reader, ActiproSoftware.Text.Lexing.ILexicalState lexicalState)    Unknown
         ActiproSoftware.Text.Wpf.dll!ActiproSoftware.Text.Lexing.Implementation.MergableLexerCoordinator.GetNextToken()    Unknown
         ActiproSoftware.Text.LLParser.Wpf.dll!ActiproSoftware.Text.Parsing.LLParser.Implementation.MergableTokenReader.GetNextToken()    Unknown
         ActiproSoftware.Text.Addons.DotNet.Wpf.dll!ActiproSoftware.Text.Languages.CSharp.Implementation.CSharpTokenReader.GetNextToken()    Unknown
         ActiproSoftware.Text.LLParser.Wpf.dll!ActiproSoftware.Text.Parsing.LLParser.Implementation.TokenReaderBase.Advance()    Unknown
         ActiproSoftware.Text.LLParser.Wpf.dll!#hSc.#WSc.#nXc(ActiproSoftware.Text.Parsing.LLParser.IParserState #Zb, #hSc.#6Sc #6Sc, ActiproSoftware.Text.Parsing.LLParser.Debugging.IDebugger #SBf)    Unknown
         ActiproSoftware.Text.LLParser.Wpf.dll!#hSc.#WSc.Parse(ActiproSoftware.Text.Parsing.LLParser.IParserState #Zb, #hSc.#6Sc #6Sc)    Unknown
         ActiproSoftware.Text.LLParser.Wpf.dll!ActiproSoftware.Text.Parsing.LLParser.Implementation.LLParserBase.Parse(ActiproSoftware.Text.Parsing.IParseRequest request)    Unknown
         ActiproSoftware.Text.Wpf.dll!ActiproSoftware.Text.Parsing.Implementation.ThreadedParseRequestDispatcher.#0Yc.#nXc(ActiproSoftware.Text.Parsing.IParseRequest #FMc)    Unknown
         ActiproSoftware.Text.Wpf.dll!ActiproSoftware.Text.Parsing.Implementation.ThreadedParseRequestDispatcher.#0Yc.#56c()    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state)    Unknown
         mscorlib.dll!System.Threading.ThreadHelper.ThreadStart()    Unknown
    Subsequent stacks are the same, with just the actual function at the top of the stack changing:
    Code:
         [Managed to Native Transition]    
    >    System.dll!System.Net.SafeCloseSocket.InnerSafeCloseSocket.Accept(System.Net.SafeCloseSocket socketHandle, byte[] socketAddress, ref int socketAddressSize)    Unknown
         System.dll!System.Net.Sockets.Socket.Accept()    Unknown
         NinjaTrader.Core.dll!NinjaTrader.Server.AtiServer.Connect.AnonymousMethod__10_0()    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state)    Unknown
         mscorlib.dll!System.Threading.ThreadHelper.ThreadStart()    Unknown
    Code:
    >    NinjaTrader.Core.dll!NinjaTrader.Server.AtiServer.Connect.AnonymousMethod__10_0()    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state)    Unknown
         mscorlib.dll!System.Threading.ThreadHelper.ThreadStart()    Unknown
    Code:
    >    NinjaTrader.Core.dll!NinjaTrader.Cbi.License.Log.AnonymousMethod__68_0(object o)    Unknown
    <etc>
    Code:
    >    NinjaTrader.Core.dll!NinjaTrader.Cbi.Log.ProcessInThread()    Unknown
    <etc>
    --EV
    Last edited by ETFVoyageur; 09-06-2016, 04:08 PM.

    Leave a comment:


  • ETFVoyageur
    replied
    Originally posted by NinjaTrader_Brett View Post
    Its almost got to be some settings in visual studio I feel. Since it only has issue when started from there.
    That's not correct. I see the exceptions in the output window, and get the threading exceptions on exit when using VS started from the NT editor -- i.e. NT started manually, not from VS.

    --EV

    Leave a comment:


  • ETFVoyageur
    replied
    Thanks, Brett,

    Funny you should say that. I just reinstalled NT8 and your zip file. The bottom line is that I can "Continue" past exceptions and get an apparently runnable NT. Here is what I did, and the result:
    • Uninstalled NT8, removed its folder, and the reinstalled it. This is totally vanilla. No settings of any kind changed, no unzipped VS stuff, no custom stuff added to the source tree.
    • Ran NT8, letting it copy over my NT7 stuff
    • Brought up the editor, did a debug mode compile, launched VS, attached to process
    • Back to the editor, recompiled, same exceptions shown
    • Connected to Kinetick, looks normal, no exceptions
    • Editor and compile, same reduced number of exceptions as in past reports
    • Created a chart, got 4 more of the FileNotFoundException
    • Exit, decline to save the workspace
    • Got the following exception 4 times ("Continue" after each one) before the exit was completed

    Code:
    An exception of type 'System.Threading.ThreadAbortException' occurred in System.dll and wasn't handled before a managed/native boundary
    
    Additional information: Thread was being aborted.
    Here is the output while exiting:
    Code:
    2016-09-06 13:13:28:709 Shutting down NinjaTrader
    2016-09-06 13:13:28:711 Disconnecting 'Kinetick – End Of Day (Free)'
    2016-09-06 13:13:28:712 (Kinetick – End Of Day (Free)) Cbi.Connection.Disconnect
    2016-09-06 13:13:28:712 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback: status=Disconnecting priceStatus=Disconnecting previousStatus=Connected previousPriceStatus=Connected errorCode=NoError nativeError=''
    2016-09-06 13:13:28:712 (Kinetick – End Of Day (Free)) Cbi.Account.OnConnectionStatus: account='Sim101' fcm='' status=Disconnecting previousStatus=Connected message=''
    2016-09-06 13:13:28:716 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close1
    2016-09-06 13:13:28:722 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close3
    2016-09-06 13:13:28:722 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close4
    2016-09-06 13:13:28:722 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close5
    2016-09-06 13:13:28:722 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close6
    2016-09-06 13:13:28:724 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close7
    2016-09-06 13:13:28:724 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback.Close8
    2016-09-06 13:13:28:726 (Kinetick – End Of Day (Free)) Kinetick.Adapter.Disconnect
    2016-09-06 13:13:28:728 (Kinetick – End Of Day (Free)) Cbi.Connection.ConnectionStatusCallback: status=Disconnected priceStatus=Disconnected previousStatus=Disconnecting previousPriceStatus=Disconnecting errorCode=NoError nativeError=''
    2016-09-06 13:13:28:729 (Kinetick – End Of Day (Free)) Cbi.Account.OnConnectionStatus: account='Sim101' fcm='' status=Disconnected previousStatus=Disconnecting message=''
    2016-09-06 13:13:28:732 Shutting down instrument management
    2016-09-06 13:13:28:735 Shutting down instrument threads
    2016-09-06 13:13:28:740 Shutting down BP thread
    2016-09-06 13:13:28:740 Shutting down data recorder
    2016-09-06 13:13:28:770 Shutting down file type watcher
    2016-09-06 13:13:28:770 Shutting down ATI server
    2016-09-06 13:13:28:772 Shutting down auto trade component
    Exception thrown: 'System.Threading.ThreadAbortException' in System.dll
    2016-09-06 13:15:24:735 Shutting down SMTP server
    Exception thrown: 'System.Threading.ThreadAbortException' in NinjaTrader.Core.dll
    2016-09-06 13:15:24:748 Shutting down adapter server
    2016-09-06 13:15:25:995 Shutting down server(s)
    2016-09-06 13:15:25:999 Shutting down mail thread
    2016-09-06 13:15:25:999 Shutting down sound thread
    2016-09-06 13:15:25:999 Shutting down timer
    2016-09-06 13:15:25:999 Shutting down alerts timer
    2016-09-06 13:15:25:999 Shutting down message timer
    2016-09-06 13:15:25:999 Shutting down db
    Exception thrown: 'System.Threading.ThreadAbortException' in NinjaTrader.Core.dll
    2016-09-06 13:15:26:023 Shutting down bars dictionary
    2016-09-06 13:15:26:027 Shutting down license threads
    Exception thrown: 'System.Threading.ThreadAbortException' in NinjaTrader.Core.dll
    2016-09-06 13:15:26:038 Shutting down logs
    Exception thrown: 'System.Threading.ThreadAbortException' in NinjaTrader.Core.dll
    Exception thrown: 'System.Threading.ThreadAbortException' in NinjaTrader.Core.dll
    Exception thrown: 'System.Threading.ThreadAbortException' in NinjaTrader.Core.dll
    2016-09-06 13:15:26:970 Shutting down bars types
    2016-09-06 13:15:28:867 Shutting down UI threads
    2016-09-06 13:15:28:870 ************************ Session End ************************
    =====


    Next I unzipped the file allowing direct use of VS and then ran VS.
    • Set the startup project
    • Add NinjaTrader.Custom project, suppressed more warnings, and added the xcopy commands
    • Rebuild the solution; all successful (modulo the usual warnings)
    • Ran NT, go the splash screen up and then the following exception

    Code:
    An exception of type 'System.ArgumentException' occurred in mscorlib.dll and wasn't handled before a managed/native boundary
    
    Additional information: Requested value 'Replay' was not found.
    • I clicked "Continue" and NT came up. The usual bunch of exceptions were shown in the output window. NT seems operational, though
    • Exit, declining to save workspace,
    • Got the same threading exceptions as reported above.

    The bottom line is that
    • The exceptions are annoying, both that they occur at all and that I need to click "Continue":
    • NT does seem fully functional once I "Continue" past exceptions
    • I worry that the exceptions could mean NT is in a strange state. If something strange happens while debugging I'll never know whether it is a bug of mine that I need to find and fix, or whether it is an artifact of something the exceptions prevented from happening.
    • It would appear that NT has a problem shutting down its threads when exiting. This is consistent, whether NT is started manually or from VS.

    --EV
    Last edited by ETFVoyageur; 09-06-2016, 02:57 PM.

    Leave a comment:


  • NinjaTrader_Brett
    replied
    Its almost got to be some settings in visual studio I feel. Since it only has issue when started from there.

    Perhaps related to changing of .net framework version or not. Just guessing at this point but for sure visual studio is related.

    Might try redownloading a new VS project with default settings. See what that does if anything. If nothing then might try reseting your visual studio settings. A google search on process to do that likely is needed.

    Leave a comment:


  • ETFVoyageur
    replied
    Th reason I emphasized the simple case is that the inability to use VS shows a lot of the same kinds of exceptions. I was hoping that the simple case would be easier to deal with, and that fixing that would fix everything.

    In the full case, I have VS set up as per that zip file you provided, Brett. I give an F5 and NT starts up as far as showing the NT8 splash screen. And then it dies with an exception:
    Code:
    An exception of type 'System.ArgumentException' occurred in mscorlib.dll and wasn't handled before a managed/native boundary
    
    Additional information: Requested value 'Replay' was not found.
    At that point the output window has
    Code:
    Exception thrown: 'System.ArgumentNullException' in System.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    WARNING: Session Break (Version 8.0.0.13)
    Cbi.Globals.MachineId: True/True 302EC07CD02EAA7D24DAC6D0CAB76B32
    Cbi.Licence.Verify5
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.ArgumentException' in mscorlib.dll
    and the stack is
    Code:
    >    mscorlib.dll!System.Enum.EnumResult.SetFailure(System.Enum.ParseFailureKind failure, string failureMessageID, object failureMessageFormatArgument)    Unknown
         mscorlib.dll!System.Enum.TryParseEnum(System.Type enumType, string value, bool ignoreCase, ref System.Enum.EnumResult parseResult)    Unknown
         mscorlib.dll!System.Enum.Parse(System.Type enumType, string value, bool ignoreCase)    Unknown
         [Native to Managed Transition]    
         [Managed to Native Transition]    
         NinjaTrader.VMRuntime.dll!lbU=.abc=.hrc=(ref object h7c=, object[] iLc=, bool ibc=, System.Reflection.MethodBase irc=, bool i7c=)    Unknown
         NinjaTrader.VMRuntime.dll!lbU=.wLo=.xLo=(lbU=.Arc= value)    Unknown
         NinjaTrader.VMRuntime.dll!lbU=.yrY=.z7Y=(lbU=.Arc= 0LY=)    Unknown
         NinjaTrader.VMRuntime.dll!VMRuntime.Libraries.CSVMRuntime.QrY=(lbU=.tbY= Q7Y=, lbU=.Arc= RLY=)    Unknown
         NinjaTrader.VMRuntime.dll!VMRuntime.Libraries.CSVMRuntime.PrY=(System.Reflection.Assembly P7Y=, string QLY=, object[] QbY=)    Unknown
         NinjaTrader.VMRuntime.dll!VMRuntime.Libraries.CSVMRuntime.RunMethod(string PQYB, object[] PgYB)    Unknown
         NinjaTrader.Core.dll!NinjaTrader.Cbi.LicenseData.LicensedProviders.set(NinjaTrader.Cbi.Provider[] value)    Unknown
         Microsoft.GeneratedCode!Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderLicenseData.Read5_LicenseData(bool isNullable, bool checkType)    Unknown
         Microsoft.GeneratedCode!Microsoft.Xml.Serialization.GeneratedAssembly.XmlSerializationReaderLicenseData.Read6_LicenseData()    Unknown
         [Native to Managed Transition]    
         [Managed to Native Transition]    
         System.Xml.dll!System.Xml.Serialization.TempAssembly.InvokeReader(System.Xml.Serialization.XmlMapping mapping, System.Xml.XmlReader xmlReader, System.Xml.Serialization.XmlDeserializationEvents events, string encodingStyle)    Unknown
         System.Xml.dll!System.Xml.Serialization.XmlSerializer.Deserialize(System.Xml.XmlReader xmlReader, string encodingStyle, System.Xml.Serialization.XmlDeserializationEvents events)    Unknown
         System.Xml.dll!System.Xml.Serialization.XmlSerializer.Deserialize(System.Xml.XmlReader xmlReader)    Unknown
         NinjaTrader.Core.dll!NinjaTrader.Cbi.License.Verify(System.Action<string, NinjaTrader.Cbi.InvalidCode, bool> errorCallback)    Unknown
         NinjaTrader.exe!NinjaTrader.AppHelper.OnStartup.AnonymousMethod__0(object o)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx)    Unknown
         mscorlib.dll!System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()    Unknown
         mscorlib.dll!System.Threading.ThreadPoolWorkQueue.Dispatch()    Unknown

    Leave a comment:


  • NinjaTrader_Brett
    replied
    Good call Koganam. Might be something there.

    I don't see anything in the trace file you sent in (as you mentioned). On case 1 and case 2 supported NT operations honestly I would not worry. Given there is nothing in the trace and we're at the limits of what I could support there. Since we've tried all the basics at this point and no operations are actually affected... however...

    You mention though that you cannot use visual studio currently? What is the problem there, might be something to chase on that front.

    Leave a comment:


  • koganam
    replied
    Could be a quasi-internal problem with serialization? ref: https://support.microsoft.com/en-us/kb/884466

    Might some extra Google Fu be in order? https://www.google.com/search?q=Exce...hrome&ie=UTF-8

    Leave a comment:


  • ETFVoyageur
    replied
    Let's take this one step at a time. I am running vanilla RC1, with nothing changed. There is no custom code in the source tree. I take the following steps:
    • Start NT8 RC1
    • New | NinjaScript Editor
    • Click on the Editor button for "Open project in Visual Studio"
    • Visual studio comes up and I attach to the NinjaTrader process
    • Back in the editor, compile (F5)
    • The compile runs, and then I hear the chime that it is done
    • Following that, I see the following exceptions appear in the VS Output window

    Code:
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.ArgumentNullException' in mscorlib.dll
    If I compile again, i get the same three exceptions after hearing the chime. Next I connected to Kinetick and recompiled. Now I get one less exception:
    Code:
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.ArgumentNullException' in mscorlib.dll
    To verify that connecting changes the behavior, I did a similar experiment, connecting first:
    • Start NT8 RC1
    • Connect to Kinetick
    • New | NinjaScript Editor
    • Click on the Editor button for "Open project in Visual Studio"
    • Visual studio comes up and I attach to the NinjaTrader process
    • Back in the editor, compile (F5)
    • The compile runs, and then I hear the chime that it is done
    • Following that, I see the following exceptions appear in the VS Output window

    Code:
    Exception thrown: 'System.IO.FileNotFoundException' in mscorlib.dll
    Exception thrown: 'System.ArgumentNullException' in mscorlib.dll
    That shows the reduced exceptions depend only on being connected, not on when you connect.

    The obvious question: what files is it trying to find (evidently after a successful compilation)? Surely the fact that connecting to Kinetick causes one of the file not found messages to go away should tell us something. It seems to me that:
    • Connecting to Kinetick making one of the file not found messages go away indicates there is a bug when no data source is connected.
    • Perhaps if we understood what files are not found we would be making progress on understanding what the problem is.
    • I am less worried about the ArgumentNullException, because there is a good chance it is just missing error checking and a consequence of the file not found problem. (If that is what it is, it would be good to fix the missing error checking.)

    BTW: it appears these messages get written to debug output, but not to the trace file. It seems to me that they should also be written to the trace file.

    --EV
    Last edited by ETFVoyageur; 09-06-2016, 01:40 AM.

    Leave a comment:


  • ETFVoyageur
    replied
    I just installed RC1, figuring it is easy to uninstall and go back to Beta 12 if need be.

    Unfortunately, all behavior remains as stated. I still get the exceptions.

    --EV

    Leave a comment:


  • ETFVoyageur
    replied
    A slightly more detailed answer:

    case 1: I bring up NT8, open the editor, recompile (debug mode, F5), open a chart (SPY, standard default template, no indicators)), and then shut down. No visible evidence of exceptions, but that is not conclusive; perhaps I just do not know where to look. I did look at trace and log files -- nothing there about any exceptions.

    case 2: identical to case 1, except that when the editor comes up I use it to launch VS and, in VS, attach to the NT process. All else is the same. Still no visible evidence of exceptions, including nothing in the log and trace files. The one thing that is different, and the reason for this thread, is that there are exceptions visible in VS. Exceptions that appear just as the compile is done (I hear the chime, then the exceptions appear in the VS Output window). More exceptions when I bring up the chart. Exit is interrupted by VS catching a threading exception.

    There are several reason these concern me, in spite of no impact on operation that I have noticed
    • It's a beta, and if there is a bug it needs to get fixed
    • The exceptions are there for a reason, so I assume NT was trying to do something that it could not complete. I have no way to know what got impacted.
    • I can no longer work by launching NT from VS. I am highly suspicious that all of these exceptions explains why.

    As I have previously noted, I have no idea why this is happening. Up until recently I have been working just fine. I have no idea what is different -- obviously something changed, but I have no idea what that might be. I do not even know how to proceed:
    • Both Case 1 and Case 2 are entirely supported operations
    • There is nothing of mine in the source tree. I deliberately did not restore my indicators and AddOns after reinstalling NT
    • I have not even changed any options in NT after reinstalling it -- I am trying to keep the test case a plain-vanilla as possible.

    Furthermore, just in case something in Windows got corrupted, I have:
    • Run Repair on each of the installed .NET components.
    • Run Repair on VS. That takes a long time and looks as if it is reinstalling everything, including the .NET it came with
    • Run several Windows checking tools; they all said they found no problems.
    • Checked for updates, in case the above set something back. No updates were found.

    I'm out of ideas. Would getting a suitable PDB file or files from you provide a better stack trace so you could tell what is going on? Do you have anything else for me to try to help diagnose the problem?

    --EV

    Leave a comment:

Latest Posts

Collapse

Topics Statistics Last Post
Started by rgoudie, Today, 08:11 PM
0 responses
1 view
0 likes
Last Post rgoudie
by rgoudie
 
Started by futures2020, 03-19-2020, 03:08 PM
2 responses
21 views
0 likes
Last Post ccl3093
by ccl3093
 
Started by taylorv817, Today, 07:19 PM
0 responses
3 views
0 likes
Last Post taylorv817  
Started by harjinderjit, Today, 06:41 PM
0 responses
10 views
0 likes
Last Post harjinderjit  
Started by tipslark, Today, 07:23 AM
1 response
31 views
0 likes
Last Post NinjaTrader_ChelseaB  
Working...
X