'Downloads all articles attached to self'

def download_articles(self, threads=1):

    urls = [a.url for a in self.articles]
    failed_articles = []
    if (threads == 1):
        for (index, article) in enumerate(self.articles):
            url = urls[index]
            html = network.get_html(url, config=self.config)
            self.articles[index].set_html(html)
            if (not html):
                failed_articles.append(self.articles[index])
        self.articles = [a for a in self.articles if a.html]
    else:
        if (threads > 5):
            print 'Using    5+    threads    on    a    single    source    may    get    you    rate    limited!'
        filled_requests = network.multithread_request(urls, self.config)
        for (index, req) in enumerate(filled_requests):
            html = network.get_html(req.url, response=req.resp)
            self.articles[index].set_html(html)
            if (not req.resp):
                failed_articles.append(self.articles[index])
        self.articles = [a for a in self.articles if a.html]
    self.is_downloaded = True
    if (len(failed_articles) > 0):
        if self.config.verbose:
            print ('[ERROR],    these    article    urls    failed    the    download:', [a.url for a in failed_articles])
