Ascoware / get-iplayer-automator

The goal of Get iPlayer Automator is to allow iTunes and your Mac to become the hub for your British Television experience regardless of where in the world you are. Currently, Get iPlayer Automator allows you to download and watch BBC and ITV shows on your Mac. Series-Link/PVR functionality ensures you will never miss your favourite shows. Programmes are fully tagged and added to iTunes automatically upon completion. It is simple and easy to use, and runs on any machine running Mac OS X 10.7 or later. And since the shows are in iTunes, it is extremely easy to transfer them to your iPod, iPhone, or Apple TV allowing you to enjoy your shows on the go or on your television.
GNU General Public License v3.0
146 stars 26 forks source link

BBC downloads changed in GiA #243

Closed nrj53 closed 5 years ago

nrj53 commented 5 years ago

GiA 1.15.1 downloads BBC radio and ITV well, as it has almost always done. Two problems just started. First, if I stop a BBC tv download and then try to restart it, it refuses to restart or continue the download stating it has already been downloaded, but it does not appear in the download file. Therefore I cannot delete the entry to try and restart the download. Second, BBC tv downloads have changed so that the audio file is downloaded, taking about 10 mins for a 1 hour show, and then the video downloads, taking about an hour for a 1 hour show. It has always been the same as ITV, downloading a 1 hour show as a single event in about 20 mins. The log for one of the BBC downloads is below.

BBC Download (ID=m0003v97): Downloading Line of Duty: Series 5 - Episode 1 INFO: 1 total programmes ERROR: Failed to download URL (3/3): https://vod-hls-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism.hlsv2.ism/iptv_hd_abr_v1_hls_master.m3u8?__gda__=1556348030_9caae7bd28fcc5e24c43a12911110da6 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-hls-uk-live.bbcfmt.hs.llnwd.net/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism.hlsv2.ism/iptv_hd_abr_v1_hls_master.m3u8?s=1556304830&e=1556348030&h=d9d03547508c8f5919bae4e1e9536c7f ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-dash-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism.hlsv2.ism/iptv_hd_abr_v1_dash_master.mpd?__gda__=1556348030_b71ec575beacc70ad298903b128f12ee ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://mm.bidi.bbc.co.uk/vod-hls-uk-live/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism.hlsv2.ism/iptv_hd_abr_v1_hls_master.m3u8?at=xztti5JCf96dddacb1a0e50ba42dd1f3bb441a287113e8e6587787c03c380 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-dash-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism/pc_hd_abr_v2_dash_master.mpd?__gda__=1556348038_e1ac046b5b11b469d0d3f2f8205f8135 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): http://vod-hls-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism/mobile_wifi_main_sd_abr_v2_hls_master.m3u8?__gda__=1556348040_76e0505529c903010369439f87506bb2 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): http://vod-hls-uk-live.bbcfmt.hs.llnwd.net/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism/mobile_wifi_main_sd_abr_v2_hls_master.m3u8?s=1556304840&e=1556348040&h=53ca9810dfb2440f534869289e513a82 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): http://mm.bidi.bbc.co.uk/vod-hls-uk-live/usp/auth/vod/piff_abr_full_sd_ad/50aa27-m0003v96/vf_m0003v96_dd1844f5-be9d-4a0c-ab7c-ef6b4c9e7270.ism/mobile_wifi_main_sd_abr_v2_hls_master.m3u8?at=18NY3fma06d19135d2d60c8bd638acf52cef8c74345823cd587787c9c5a00 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-hls-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism.hlsv2.ism/iptv_hd_abr_v1_hls_master.m3u8?__gda__=1556348044_e25d75c81f9344d595047ffc05551601 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-dash-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism.hlsv2.ism/iptv_hd_abr_v1_dash_master.mpd?__gda__=1556348044_128e3759bf5fb376994f3c425e4c8d12 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-hls-uk-live.bbcfmt.hs.llnwd.net/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism.hlsv2.ism/iptv_hd_abr_v1_hls_master.m3u8?s=1556304844&e=1556348044&h=ade198e81359b41a37b2476e8bafa7c4 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://mm.bidi.bbc.co.uk/vod-hls-uk-live/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism.hlsv2.ism/iptv_hd_abr_v1_hls_master.m3u8?at=YVkefQ72d71fd7b9796b6462a44cd4b0005057e6e7939ad3587787cd96300 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): https://vod-dash-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism/pc_hd_abr_v2_dash_master.mpd?__gda__=1556348051_92cde145896c05c83f0b06c799be65b0 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): http://vod-hls-uk-live.akamaized.net/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism/mobile_wifi_main_sd_abr_v2_hls_master.m3u8?__gda__=1556348053_4fa401c362d221cbe9adef7873acf152 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): http://vod-hls-uk-live.bbcfmt.hs.llnwd.net/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism/mobile_wifi_main_sd_abr_v2_hls_master.m3u8?s=1556304853&e=1556348053&h=1e1ffe675668190794398783da885450 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful ERROR: Failed to download URL (3/3): http://mm.bidi.bbc.co.uk/vod-hls-uk-live/usp/auth/vod/piff_abr_full_hd/50aa27-m0003v96/vf_m0003v96_d25ad0c7-d29b-4f42-a8d9-d185274d0121.ism/mobile_wifi_main_sd_abr_v2_hls_master.m3u8?at=Woy_sS0075bb9d136c6e02f3a5425afa0fc4d92450a7bafa587787d62b740 ERROR: Response: 403 Forbidden ERROR: Ignore this error if programme download is successful WARNING: A UK TV licence is required to access BBC iPlayer TV content legally INFO: Downloading tv: 'Line of Duty: Series 5 - 01. Episode 1 (m0003v97) [original]' INFO: Downloaded: 40.31 MB (00:56:11) @ 0.53 Mb/s (dvfxsd1/ll) [audio] INFO: Finished downloading to file: /Users/Ross 1/Movies/TV Shows/Line of Duty Series 5/Line of Duty Series 5 - 01. Episode 1 ((dvfxsd)).audio.m4a INFO: Downloaded: 674.31 MB (00:57:39) @ 1.57 Mb/s (dvfxsd1/ll) [video] INFO: Finished downloading to file: /Users/Ross 1/Movies/TV Shows/Line of Duty Series 5/Line of Duty Series 5 - 01. Episode 1 ((dvfxsd)).video.m4v INFO: Converting to MPEG-TS INFO: Converting to MP4 INFO: Tagging MP4 BBC Download (ID=m0003v97): Line of Duty: Series 5 - Episode 1 Completed Successfully AppController: Downloads Finished Adding Line of Duty: Series 5 - Episode 1 to iTunes

skovatch commented 5 years ago

The ERROR: Response: 403 Forbidden means that the BBC has detected you are outside the UK and is blocking downloads. The errors are coming from get_iplayer -- it keeps trying different content hosts, though it's interesting that eventually finds one that gives you the show in DVF format. get_iplayer downloads the audio and video separately and then combines them into an MP4.

For what it's worth, when I download this show I get a lot of 404 errors before it eventually finds a provider.

nrj53 commented 5 years ago

Thanks very much for the quick explanation. Glad that it is not GiA. The onus is on me to find a different vpn.

Ross.

Sent from my iPad

On Apr 27, 2019, at 2:51 PM, Scott Kovatch notifications@github.com wrote:

The ERROR: Response: 403 Forbidden means that the BBC has detected you are outside the UK and is blocking downloads. The errors are coming from get_iplayer -- it keeps trying different content hosts, though it's interesting that eventually finds one that gives you the show in DVF format. get_iplayer downloads the audio and video separately and then combines them into an MP4.

For what it's worth, when I download this show I get a lot of 404 errors before it eventually finds a provider.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

hugofalkman commented 5 years ago

@skovatch Would it be possible to test for the 403 message, and then issue a GiA message saying BBC/ITV has blocked your VPN/SmartDNS provider? It would keep a lot of stuff out of our mail inbaskets.

nrj53 commented 5 years ago

I appreciate that these sort of issues must be a nuisance. Simply knowing the meaning of the error code means that now I can look at the log and see the problem. If there is somewhere I can look at a list of error codes that would be great and possibly save you both a lot of aggravation. The only problem with flagging 403 is that GiA kept looking and eventually finds a working link, and that might be cut off by a warning. I have simply moved to a different vpn and downloaded the next episode normally and in a few minutes. But even with that success, GiA ran through several attempts and 403 errors before proceeding. Thanks again.

skovatch commented 5 years ago

This reminds me that get_iplayer used to print out a message about the BBC blocking you, and GiA would display it in the Solutions window. I think that message changed at some point, and GiA now just says "Unknown Error". I can update for that, and also see if that was the last error message received. It won't apply in this situation, but some improved error handling will be helpful in the future.

skovatch commented 5 years ago

Closing, as this is VPN-related.

michaelrcowie commented 5 years ago

I referenced this post this evening, to solve this problem with help from my VPN support folks.

I suddenly found my GIA downloads were ridiculously slow, and checked my log to find the same string of 403 (and 500!) warnings posted above. After a LONG pause at the end of multiple attempts to connect to something, GIA would start downloading a show and tell me that the 1 hour show would take 3 hours to download. Everything was fine a few days ago, so I knew it was probably the VPN and not the app.

I contacted ExpressVPN, and they said they had clients complaining via live chat all night about some of their servers, specifically when using BBC steaming. EVPN's first piece of advice was to change servers - which made no difference to GIA, or made the problem worse. Then they asked how I was connecting to the BBC, and I confirmed that I had no problem watching in a browser on the new server connection, but the app I wanted to use was still stupidly slow.

Since they didn't know what GIA was (or were not allowed to admit they did) they were stumped. After some flailing around, they then suggested I change connection protocol - and that solved the problem.

I was on an UDP or TCP OpenVPN protocol, and as soon as I changed over to L2TP - IPSe in the app control panel, my downloads immediately went back to the speed I expected. In the time it has taken me to post this, I've got the Craig Charles shows for the weekend, a film, the Line of Duty finale, QI:XL and the last two episodes of Follow the Money, all in HD. The log still shows multiple connection attempts and is downloading multiple files (which it was not doing the other day), but is way faster than earlier this evening.

I can see why a VPN might not see this kind of thing as their problem to solve, and I'm lucky the fellow I was dealing with decided not to give up on me. You may want to do some checking into what settings you can change in the sort term before you spend your time searching for a new VPN.

Now if you'll excuse me, I have some TV to watch...

stoney27 commented 5 years ago

Quick question Michael what platform are you running your ExpressVPN on? I have the ExpressVPN router setup, and unfortunately, it doesn't seem to have that connection setting.

Michael if you want to respond via Email

Thanks.

PS. Scott sorry to use this as a VPN debug session I would have sent Michael email, but GitHub doesn't have that as an option.

michaelrcowie commented 5 years ago

Mac, on Hackintosh.

I should point out that this solution is not perfect. I logged in this morning to grab one small show, and had to try a few times before I got the same result. I also noticed that two of the UK servers my VPN uses were removed since last night. They may be doing what I suggested, and getting some new UK IP addresses to use.