--info and --{metadata,subtitles,thumbnail}-only now work with --pid

Vangelis forthnet northmedia1 at the.forthnet.gr
Mon Oct 20 21:59:57 PDT 2014


 Hi dinkypumpkin :-)

https://github.com/dinkypumpkin/get_iplayer/wiki/release287#--info-and---metadatasubtitlesthumbnail-only-now-work-with---pid

(FYI: The above wiki entry reflects the changes made by commit git-5efd13b:

http://git.infradead.org/get_iplayer.git/commit/5efd13bde66efc597ad9360629e98ac292df1ad4 )

You state:

> The --pid option previously invoked an immediate download
> regardless of the other options specified.
> Now ...  --metadata-only, --subtitles-only or --thumbnail-only
> will short-circuit that behaviour and perform their usual functions.

My locally patched copy of the script is well pre-2.87, but when I run, 
e.g.:

get_iplayer --pid=b04m0l3g --force --subtitles-only
get_iplayer --pid=b04m0l3g --force --thumbnail-only

the switches DO PERFORM their usual functions, i.e.
only the subs/thumbnail get fetched.

In fact, if you open the commitdiff
http://git.infradead.org/get_iplayer.git/commitdiff/5efd13bde66efc597ad9360629e98ac292df1ad4
you'll see that the commented-out line reads:

# Don't do a pid recording if metadataonly or thumbonly were specified

so what you state in the wiki for "--*-only" was already happening...
By looking at the code you added, the "# ..." line should now read:

# Don't do a pid recording if metadataonly or thumbonly or subsonly or info 
were specified

But the above is true ONLY FOR PIDs IN THE CACHE.

If I try a non-indexed programme, e.g.

http://www.bbc.co.uk/programmes/p028s8f9
(this was never in the tv cache to begin with)

get_iplayer --pid=p028s8f9 --force --thumbnail-only

FAILS with "INFO: pid not found in tv cache"
(whereas get_iplayer --pid=p028s8f9 --force works!).

If I also try another programme that was initially in the
tv cache but now is not (> 7d old), e.g. pid=b04lckj1,
that also fails:

get_iplayer --pid=b04lckj1 --force --subtitles-only
(but get_iplayer --pid=b04lckj1 --force --subtitles
WORKS with the patched 2.86 - former GIT HEAD -
version of GiP).
Is this the expected behaviour and if yes, could it be fixed/
is it fixed in 2.87+ ?

> The --pid option previously invoked an immediate download
> regardless of the other options specified.

This was (pre-2.87) indeed true for --info; in fact, I am used to
typing together "-i --pid=[pid]" so that my command prompt
window first displays the available metadata and then moves on
to the downloading part...
I understand that with 2.87 only the metadata will be shown:

get_iplayer --type=radio -i --pid=b04ksl4f

Is there anything I could add in 2.87 (perhaps -g) to
revert to the previous behaviour?

Apologies for the lengthy(-ish) mail and, as ever,
much kudos for your coding...

Best regards,
Vangelis. 




More information about the get_iplayer mailing list