You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bump! I would really love to know how to disable this annoying message every time I use the library:
Exception occured resolving a log provider. Logging for this assembly uhttpsharp
, Version=0.1.5653.28566, Culture=neutral, PublicKeyToken=null is disabled. Syst
em.TypeInitializationException: The type initializer for 'uhttpsharp.Logging.Log
Providers.ColouredConsoleLogProvider' threw an exception. ---> System.InvalidOpe
rationException: System.Console or System.ConsoleColor type not found
at uhttpsharp.Logging.LogProviders.ColouredConsoleLogProvider..cctor() in c:
Users\shani\Documents\GitHub\uHttpSharp\uhttpsharp\App_Packages\LibLog.3.1\LibLo
g.cs:line 1629
--- End of inner exception stack trace ---
at uhttpsharp.Logging.LogProviders.ColouredConsoleLogProvider.IsLoggerAvailab
le() in c:\Users\shani\Documents\GitHub\uHttpSharp\uhttpsharp\App_Packages\LibLo
g.3.1\LibLog.cs:line 1645
at uhttpsharp.Logging.LogProvider.ResolveLogProvider() in c:\Users\shani\Docu
ments\GitHub\uHttpSharp\uhttpsharp\App_Packages\LibLog.3.1\LibLog.cs:line 453
Why can't you just let the exception bubble up so I can catch it?
Activity
bonesoul commentedon Jul 29, 2016
only console.write reference is in the demo project? are you sure the log lines you mention are from uhttpsharp?
beppe9000 commentedon Jul 29, 2016
This one, for example:
uhttpsharp/uhttpsharp/HttpServer.cs
Line 66 in e3ac7fc
sirkris commentedon Feb 6, 2019
Bump! I would really love to know how to disable this annoying message every time I use the library:
Exception occured resolving a log provider. Logging for this assembly uhttpsharp
, Version=0.1.5653.28566, Culture=neutral, PublicKeyToken=null is disabled. Syst
em.TypeInitializationException: The type initializer for 'uhttpsharp.Logging.Log
Providers.ColouredConsoleLogProvider' threw an exception. ---> System.InvalidOpe
rationException: System.Console or System.ConsoleColor type not found
at uhttpsharp.Logging.LogProviders.ColouredConsoleLogProvider..cctor() in c:
Users\shani\Documents\GitHub\uHttpSharp\uhttpsharp\App_Packages\LibLog.3.1\LibLo
g.cs:line 1629
--- End of inner exception stack trace ---
at uhttpsharp.Logging.LogProviders.ColouredConsoleLogProvider.IsLoggerAvailab
le() in c:\Users\shani\Documents\GitHub\uHttpSharp\uhttpsharp\App_Packages\LibLo
g.3.1\LibLog.cs:line 1645
at uhttpsharp.Logging.LogProvider.ResolveLogProvider() in c:\Users\shani\Docu
ments\GitHub\uHttpSharp\uhttpsharp\App_Packages\LibLog.3.1\LibLog.cs:line 453
Why can't you just let the exception bubble up so I can catch it?
isen-ng commentedon Feb 20, 2019
Do this for a work around:
robie2011 commentedon May 26, 2020
same issue. Workaround didn't work.