def __init__(self): self.reader = None self.base_re = re.compile('http://([^.]+).wikipedia.org/wiki/(.+)') self.__load_data() self.reader = {} self.parser = Parser() self.cache = Cache() self.all_pages = None self.mime_types = {} # Language index file = os.path.join(base_dir, 'languages.txt') self.all_languages = load_languages(file) # Template global template_dir self.template = TemplateLookup(directories=[template_dir])