Closed wotd closed 8 years ago
Check the newest more clean and compressed version of the script. Should your problem be fixed
Sorry, stil same problem. It looks like there is a problem with ebooks with dash in title?
weird, i have dwnloaded all the titles from the account and worked correctly, Can you give me the exact title you come across a problem with ?
This error occurs before script display title. But \u2013 is dash I think, so I suspect this book: "Kali Linux – Assuring Security by Penetration Testing [eBook] "
tested both on windows7 and ubuntu with Python ver 2.7 and 3.5 and seems to work without any with this title. Please check the latest version once again and let me know
Had the same issue with that very book that wotd reported.... My code change at the link below resolves the issue: https://github.com/trancen/Packt-Publishing-Free-Learning/commit/894927b4d33687e76524eb9c4d9ae13c27fb0bb0
during packtFreeBookDownloader.py execution:
Traceback (most recent call last): File "packtFreeBookDownloader.py", line 187, in
downloader.downloadBooks(downloader.downloadBookTitles, downloader.downloadFormats)
File "packtFreeBookDownloader.py", line 156, in downloadBooks
if(os.path.isfile(fullFilePath)):
File "/usr/lib/python2.7/genericpath.py", line 37, in isfile
st = os.stat(path)
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2013' in position 31: ordinal not in range(128)