r81372 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r81371‎ | r81372 | r81373 >
Date:02:43, 2 February 2011
Author:diederik
Status:deferred
Tags:
Comment:
Fixed issue where customized configuration was overwritten with default setting.
Modified paths:
  • /trunk/tools/editor_trends/configuration.py (modified) (history)

Diff [purge]

Index: trunk/tools/editor_trends/configuration.py
@@ -97,9 +97,10 @@
9898 self.tab_width = 4 if self.platform == 'Windows' else 8
9999
100100
 101+ result = self.load_configuration()
 102+ if not result:
 103+ self.input_location = os.path.join(self.root, 'wikimedia')
101104
102 - self.input_location = os.path.join(self.root, 'wikimedia')
103 - self.load_configuration()
104105 # Default Input file
105106 self.input_filename = os.path.join(self.input_location, 'en',
106107 'wiki',
@@ -128,6 +129,9 @@
129130 self.input_location = config.get('file_locations', 'input_location')
130131 self.default_project = config.get('wiki', 'project')
131132 self.default_language = config.get('wiki', 'language')
 133+ return True
 134+ else:
 135+ return False
132136
133137 def determine_working_directory(self):
134138 cwd = os.getcwd()

Status & tagging log