[Pywikipedia-l] SVN: [6384] branches/rewrite/pywikibot/config2.py

nicdumz at svn.wikimedia.org nicdumz at svn.wikimedia.org
Fri Feb 20 06:59:40 UTC 2009


Revision: 6384
Author:   nicdumz
Date:     2009-02-20 06:59:40 +0000 (Fri, 20 Feb 2009)

Log Message:
-----------
Using a logger here is maybe too much. Using prints, since pywikibot.output is not available yet when config is loaded

Modified Paths:
--------------
    branches/rewrite/pywikibot/config2.py

Modified: branches/rewrite/pywikibot/config2.py
===================================================================
--- branches/rewrite/pywikibot/config2.py	2009-02-20 05:27:52 UTC (rev 6383)
+++ branches/rewrite/pywikibot/config2.py	2009-02-20 06:59:40 UTC (rev 6384)
@@ -8,10 +8,8 @@
 
 import os, re
 import sys as __sys
+import pywikibot
 
-import logging
-logger = logging.getLogger("wiki.config2")
-
 # IMPORTANT:
 # Do not change any of the variables in this file. Instead, make
 # a file user-config.py, and overwrite values in there.
@@ -506,9 +504,9 @@
             print "         %(was)s: %(new)s" % {'now': "Now", 'new': nt}
         del nt,ot
     else:
-        logger.warn(
-    "Configuration variable %(_key)r is defined but unknown. Misspelled?\n"
-            % locals())
+        print \
+            "Configuration variable %(_key)r is defined but unknown."\
+            " Misspelled?" % locals()
 
 # Fix up default console_encoding
 if console_encoding == None:





More information about the Pywikipedia-l mailing list