web-settings-and-get_iplayer-defaults-harmonisation

Pete Beardmore pete.beardmore at msn.com
Wed Jan 30 17:39:49 EST 2013




#patch attached (hopefully!)


hi,


as a new user a few months ago i was a little frustrated as i couldn't work out where settings that were used came from. specifically with 'modes', as i wanted HD and it didn't work out of the box.


having tried combinations of 'flashhd,flashhd1,flashhd2' in option files and in the webserver to no avail, i settled on 'best' (having finally resorted to reading instructions!). this was set in my options files under /srv/www/iplayer/.get_iplayer but still, via the web server (be it my apache or the included standalone), i could not get the underlying flvstreamer/rtmpdump processes to behave and show me that attempts at flashhd1 etc. quality streams were being made.


so mistake #1. although the instruction state that one should ensure HOME is set correctly, don't assume that that is for reading any options files which you might have created there (/srv/www/iplayer/get_iplayer/options) whilst trying out the 'get_iplayer' script. the web server doesn't read them!


mistake #2. ALWAYS use the --prefs-add fuctionality to add options to the options file to ensure you get the right format! for example, the entry..


modes 'best,flashhd,flashhd1,flashhd2,flashvhigh'


..f@&Sed me over as i'd add quotes!


anyway. finally i got up and running and so on to the hackery. the attached patch makes the web server work as i want it to with regard to where defaults come from. specifically it:


1. only persists web setting as cookies when none default
2. adds ability to return settings back to defaults
3. bases defaults on get_iplayer option files
4. harmonises defaults structure through single opt_defaults array


use cases:


1. 20+ empty default is bad, particularly when i have to scroll through them all to find non get_iplayer related cookies on my (apache) server
2. i wanted to delete all get_iplayer related cookies and go back to the default set of columns
3. i've made the effort to add 'excludecategory' / 'exlcudechannel' options in my options file, i don't want to change those is multiple places. and if i've set something as important as 'modes' for use with 'get_iplayer' then i really want that same setting used in the web front end
4. specifically modes (originally default_modes) and cols (originally default_headings) which didn't even feature in the original option structure->default mechanism.


hope this is seen as an improvement, in spite of the rather clueless way i happened on requiring the changes :)


cheers




 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.infradead.org/pipermail/get_iplayer/attachments/20130130/42c88c44/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-web-settings-and-get_iplayer-defaults-harmonisation.patch
Type: application/octet-stream
Size: 15035 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/get_iplayer/attachments/20130130/42c88c44/attachment-0001.obj>


More information about the get_iplayer mailing list