Revision: 8454 Author: valhallasw Date: 2010-08-24 21:42:34 +0000 (Tue, 24 Aug 2010)
Log Message: ----------- Added another monkey patch to prevent config.py from loading user-config.py.
Modified Paths: -------------- trunk/pywikipedia/generate_family_file.py
Modified: trunk/pywikipedia/generate_family_file.py =================================================================== --- trunk/pywikipedia/generate_family_file.py 2010-08-24 21:35:36 UTC (rev 8453) +++ trunk/pywikipedia/generate_family_file.py 2010-08-24 21:42:34 UTC (rev 8454) @@ -32,6 +32,12 @@ # Monkey-patching wikipediatools to prevent questions about user_config.py import wikipediatools wikipediatools.get_base_dir = lambda: '.' + +# Monkey-patch os.path.exists to prevent config.py from loading user_config.py +import os.path +os.path.exists = lambda x: False + +# Now we can load family.py import family
class FamilyFileGenerator(object):
pywikipedia-svn@lists.wikimedia.org