artivis / rpipress-downloader

Download Raspberry Pi Press issues
MIT License
18 stars 5 forks source link

Errors due to delayed free pdf #6

Closed tripplehelix closed 8 months ago

tripplehelix commented 1 year ago

The script currently throws errors as the magazine was released, but it's behind a timer.

Would it be possible to grab the date of release of the current issue then calculate the time till release and display that instead of the error? I think they are released for free 2-3 weeks after print release.

tripplehelix commented 8 months ago

The only issue I see from this is the gap between PDF release and new release is the only time it'll download the PDF. If the new release has come out, it just errors and doesn't just instead download or make sure the previous magazine has been downloaded.

tripplehelix commented 8 months ago

For example, I ran the script today with an empty ~/rpipress folder, and it only downloaded one of the magazines and cast an error on the others. The error it throws 'you may need to wait' was a stop gap, between what it currently does and a fix.

artivis commented 8 months ago

I get your point. I can suggest 2 workarounds:

Do you happen to know if a 'new issue' happens before a 'free issue'? In which case the first workaround wouldn't even work.

tripplehelix commented 7 months ago

If error, then download issue -1 ?

If issue -1 exists then "you are up to date"

"Do you happen to know if a 'new issue' happens before a 'free issue'? In which case the first workaround wouldn't even work." I don't know their release schedule, I think it's like two or three weeks after paper release.