]> granicus.if.org Git - python/commitdiff
Use PEP-8 style in logging example
authorJason R. Coombs <jaraco@jaraco.com>
Wed, 7 Mar 2012 15:24:04 +0000 (10:24 -0500)
committerJason R. Coombs <jaraco@jaraco.com>
Wed, 7 Mar 2012 15:24:04 +0000 (10:24 -0500)
Doc/library/logging.rst

index f91d4845c1128aee46a18018b424fa3069fa24f6..665485d660450ce45cc80bcf072c2dcc05170513 100644 (file)
@@ -138,7 +138,7 @@ instantiated directly, but always through the module-level function
 
       FORMAT = '%(asctime)-15s %(clientip)s %(user)-8s %(message)s'
       logging.basicConfig(format=FORMAT)
-      d = { 'clientip' : '192.168.0.1', 'user' : 'fbloggs' }
+      d = {'clientip': '192.168.0.1', 'user': 'fbloggs'}
       logger = logging.getLogger('tcpserver')
       logger.warning('Protocol problem: %s', 'connection reset', extra=d)