Hi MK,
at
exceptions
ck-into-log-file/
I've just given this solution a shot but I still seem to get the same
result, it suddenly starts dumping the log data to the command line, and
nothing gets printed in error.txt apart from the keyboard interrupt from
when I kill the application.
For some reason the exceptions don't seem to be raised properly so obviously
aren't being caught at this higher level.
So confusing.
>>Robert Rawlins wrote:
>>
>I certainly like that implementation for logging the exceptions, however,
>>
>I certainly like that implementation for logging the exceptions, however,
>the moment I don't even know where the exceptions are occurring, or what
>type they are, could I still use this method to log any and all
>type they are, could I still use this method to log any and all
>raised in the application?
Remember, Google is your friend, here's the crux of the method without
the fancy schmancy sugar coating:
>
>
the fancy schmancy sugar coating:
>
>
ck-into-log-file/
>
if __name__=="__ma in__":
try:
main()
except:
print "Trigger Exception, traceback info forward to log file."
traceback.print _exc(file=open( "errlog.txt","a "))
sys.exit(1)
>
if __name__=="__ma in__":
try:
main()
except:
print "Trigger Exception, traceback info forward to log file."
traceback.print _exc(file=open( "errlog.txt","a "))
sys.exit(1)
>
result, it suddenly starts dumping the log data to the command line, and
nothing gets printed in error.txt apart from the keyboard interrupt from
when I kill the application.
For some reason the exceptions don't seem to be raised properly so obviously
aren't being caught at this higher level.
So confusing.