tim-morriss / pyscrapeTrain

Python script for downloading tracks from TrakTrain (similar function to ScrapeTrainV2)
Other
5 stars 0 forks source link

only downloads 1 page (40 tracks) even if multiple pages exist #3

Closed HeartbeatingForCenturies closed 11 months ago

HeartbeatingForCenturies commented 11 months ago

seems to only download one page of https://traktrain.com/ddertbag

i found you can sort the pages by changing the number at the end of this url https://traktrain.com/profile-tracks/23438?search=&sort=latest&page=1

mativerval commented 11 months ago

i found you can sort the pages by changing the number at the end of this url https://traktrain.com/profile-tracks/23438?search=&sort=latest&page=1

Hi, i'm trying to sort the pages as well, when I tried to download this link I got this error:

"Traceback (most recent call last): File "C:\Users\Documents\pyscrapeTrain-master\scrapeTrain.py", line 166, in scrape_train(tt_url, output_dir) File "C:\Users\Documents\pyscrapeTrain-master\scrapeTrain.py", line 34, in scrape_train soup.find("h1", {"class": "profile-bio__name"}).text AttributeError: 'NoneType' object has no attribute 'text' =latestThe system cannot find the file specified. 'page' is not recognized as an internal or external command, operable program or batch file."

Is there something else you have to do to download different pages? I notice the link leads to a source page, is there anyway to sort the pages of the normal traktrain URL?

tim-morriss commented 11 months ago

Good spot, this is an issue. Thanks @HeartbeatingForCenturies for the link, I'll use that format to fix it.

tim-morriss commented 11 months ago

Just pushed a update to fix this, used the page feature, thanks again.