diff options
author | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2005-02-18 11:54:46 (GMT) |
---|---|---|
committer | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2005-02-18 11:54:46 (GMT) |
commit | 612df8e21ded5a6d7c0f6641f16422883c61b4d9 (patch) | |
tree | 9974aa3a67e377ad2dbf172115969ba312d6f4db /Lib/logging/config.py | |
parent | 829dc51a050a68ca79cdde298697d0344639bd14 (diff) | |
download | cpython-612df8e21ded5a6d7c0f6641f16422883c61b4d9.zip cpython-612df8e21ded5a6d7c0f6641f16422883c61b4d9.tar.gz cpython-612df8e21ded5a6d7c0f6641f16422883c61b4d9.tar.bz2 |
Handle errors in imports of thread, threading
Diffstat (limited to 'Lib/logging/config.py')
-rw-r--r-- | Lib/logging/config.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Lib/logging/config.py b/Lib/logging/config.py index 92f2af0..a5c780f 100644 --- a/Lib/logging/config.py +++ b/Lib/logging/config.py @@ -27,7 +27,13 @@ Copyright (C) 2001-2004 Vinay Sajip. All Rights Reserved. To use, simply 'import logging' and log away! """ -import sys, logging, logging.handlers, string, thread, threading, socket, struct, os +import sys, logging, logging.handlers, string, socket, struct, os + +try: + import thread + import threading +except ImportError: + thread = None from SocketServer import ThreadingTCPServer, StreamRequestHandler |