mirror of
https://github.com/KevinMidboe/ITLscraper.git
synced 2025-10-29 01:30:14 +00:00
Update utf8 errro
This commit is contained in:
2
app.py
2
app.py
@@ -15,7 +15,7 @@ def download(btn):
|
||||
selected = app.getCheckBox(courses[label])
|
||||
if selected:
|
||||
course_links[label]=courses[label]
|
||||
print(course_links)
|
||||
#print(course_links.encode('utf-8'))
|
||||
|
||||
print("Download selected")
|
||||
scraper.download_links(course_links)
|
||||
|
||||
@@ -146,9 +146,10 @@ class itslearning_scraper():
|
||||
except:
|
||||
filename = title
|
||||
self.failure += 1
|
||||
print("File created with name:",filename)
|
||||
filename = slugify(filename)
|
||||
print("File created with name:",filename)
|
||||
filename = os.path.join(os.path.abspath(os.path.curdir),filename)
|
||||
print("File created with path:",filename)
|
||||
with open(filename, 'wb') as f:
|
||||
for chunk in r.iter_content(chunk_size=1024):
|
||||
if chunk:
|
||||
|
||||
Reference in New Issue
Block a user