Closed yudilee closed 6 years ago
While i try to create epub from webnovel i got error invalid literal for int() with base 10:
python3 main.py webnovel 10377938706023605 https://www.webnovel.com/book/10377938706023605/27858104469219628/Last-Wish-System/Yale-Roanmad https://www.webnovel.com/book/10377938706023605/30154170363336851/Last-Wish-System/Crossing-the-Border Getting CSRF Token from https://www.webnovel.com/book/10377938706023605 CSRF Token = 9eJJFX5txT0r9s3004p1rDY61DZrTfvslGGHmp61 Getting book name and chapter list... 148 chapters found Traceback (most recent call last): File "main.py", line 2, in main() File "/home/yudi/book/Web Scrapper/ebook_crawler/init.py", line 34, in main end_chapter=sys.argv[4] if len(sys.argv) > 4 else '' File "/home/yudi/book/Web Scrapper/ebook_crawler/webnovel.py", line 43, in start self.get_chapter_bodies() File "/home/yudi/book/Web Scrapper/ebook_crawler/webnovel.py", line 83, in get_chapter_bodies start = int(self.start_chapter) ValueError: invalid literal for int() with base 10: 'https://www.webnovel.com/book/10377938706023605/27858104469219628/Last-Wish-System/Yale-Roanmad'
Thanks for helping
Hello @yudilee . Please use chapter numbers instead.
For example: ebook_crawler webnovel 10377938706023605 1 115
ebook_crawler webnovel 10377938706023605 1 115
fixed in latest release
While i try to create epub from webnovel i got error invalid literal for int() with base 10:
python3 main.py webnovel 10377938706023605 https://www.webnovel.com/book/10377938706023605/27858104469219628/Last-Wish-System/Yale-Roanmad https://www.webnovel.com/book/10377938706023605/30154170363336851/Last-Wish-System/Crossing-the-Border Getting CSRF Token from https://www.webnovel.com/book/10377938706023605 CSRF Token = 9eJJFX5txT0r9s3004p1rDY61DZrTfvslGGHmp61 Getting book name and chapter list... 148 chapters found Traceback (most recent call last): File "main.py", line 2, in
main()
File "/home/yudi/book/Web Scrapper/ebook_crawler/init.py", line 34, in main
end_chapter=sys.argv[4] if len(sys.argv) > 4 else ''
File "/home/yudi/book/Web Scrapper/ebook_crawler/webnovel.py", line 43, in start
self.get_chapter_bodies()
File "/home/yudi/book/Web Scrapper/ebook_crawler/webnovel.py", line 83, in get_chapter_bodies
start = int(self.start_chapter)
ValueError: invalid literal for int() with base 10: 'https://www.webnovel.com/book/10377938706023605/27858104469219628/Last-Wish-System/Yale-Roanmad'
Thanks for helping