Permalink
Browse files

Changed logging format

 * fmt: 'time level message'
  • Loading branch information...
1 parent 71cdd36 commit 346a0627f84f92739e4fa2d27b15cb9ce90eca5d @omartinak omartinak committed Jul 2, 2011
Showing with 4 additions and 3 deletions.
  1. +3 −2 fishtank.py
  2. +1 −1 src/curses_cio.py
View
@@ -31,14 +31,15 @@
print("Unsupported platform '%s' - fishtank runs only on posix platforms" % (os.name))
sys.exit(1)
- logging.basicConfig(filename="fish.log", filemode='w', level=logging.INFO)
+ fmt = '%(asctime)s %(levelname)s %(message)s'
+ logging.basicConfig(filename="fish.log", filemode='w', level=logging.INFO, format=fmt)
cio = CursesCIO()
cio.init()
logging.info("initialized")
if not cio.has_colors():
- logging.info("colors are not supported")
+ logging.warning("colors are not supported")
tank = Tank(cio.getTermWidth(), cio.getTermHeight())
View
@@ -41,7 +41,7 @@ def init(self):
try:
curses.curs_set(0)
except:
- logging.info("cursor hiding is not supported")
+ logging.warning("cursor hiding is not supported")
curses.halfdelay(1) # block for 0.1s

0 comments on commit 346a062

Please sign in to comment.