http://www.mediawiki.org/wiki/Special:Code/pywikipedia/11251
Revision: 11251 Author: xqt Date: 2013-03-24 11:34:13 +0000 (Sun, 24 Mar 2013) Log Message: ----------- Ignore tzset() if that attribute does not exist. Should be fixed.
Modified Paths: -------------- trunk/pywikipedia/subster.py
Modified: trunk/pywikipedia/subster.py =================================================================== --- trunk/pywikipedia/subster.py 2013-03-24 11:13:03 UTC (rev 11250) +++ trunk/pywikipedia/subster.py 2013-03-24 11:34:13 UTC (rev 11251) @@ -161,7 +161,11 @@
# modification of timezone to be in sync with wiki os.environ['TZ'] = 'Europe/Amsterdam' - time.tzset() + + # windows doesn't have that attribute + # TODO: fix it + if hasattr(time, "tzset"): + time.tzset() pywikibot.output(u'Setting process TimeZone (TZ): %s' % str(time.tzname)) # ('CET', 'CEST')
# init constants
pywikipedia-svn@lists.wikimedia.org