English-words-pronunciation-mp3-audio-download
English-words-pronunciation-mp3-audio-download copied to clipboard
issue with ultimate.json
i try to use ultimate.json rather than data.json
DATA_FILE = 'ultimate.json'
but there is an issue with url
`class DownloadWorker(Thread): # 'pairs' is a dictionary def init(self, pk, pairs, dir_path, statistics): Thread.init(self) self.pk = pk self.pairs = pairs self.dir_path = dir_path self.statistics = statistics
def run(self):
for word, url in self.pairs.items():
# if os.path.exists(os.path.join(self.dir_path, word + MP3_FILENAME_EXTENSION)):
# self.statistics.decrease_total()
# continue
current = self.statistics.increase_current()
print('(' + str(current) + '/' + str(self.statistics.total) + ') ' + word)
download_mp3(word, url, self.dir_path)`
in last line url is
['http://img2.tfd.com/pron/mp3/en/US/d3/d3djdysfd7dydssfhfdosssls3sdsksls3gjgy.m p3', 'http://www.yourdictionary.com/audio/a/af/african-american.mp3', 'http://im g2.tfd.com/pron/mp3/en/UK/d3/d3djdysfd7dydssfhfdosssls3sdsksls3gjgy.mp3']
that seems it is not compatible with 'download_mp3'
module
should i change something else? or the code needs some change?
Warm regards,
Hi! Thank you for your interests in this project. Can you send me an email at [email protected] and let's discuss about this further?