[mythtv] Ticket #9853: mythfilldatabase no longer recognises "--graboptions"

Raymond Wagner raymond at wagnerrp.com
Thu Jun 16 18:56:53 UTC 2011

On 6/16/2011 12:56, Karl Dietz wrote:
> Before this turns into a discussion on trac...
> On 16.06.2011 18:23,  MythTV wrote:
>> #9853: mythfilldatabase no longer recognises "--graboptions"
>>    ahh - well my tv_grab_au is actually "shepherd" (http://svn.whuffy.com/)
> Shepherd suggests to run a hourly cronjob of mythfilldatabase with
> graboption --daily which means "only do something once around every
> 24h". Maybe that's because cron on linux usually sucks or whatever.
> The correct setup is, of course, to just pick shephard as the grabber
> and let the master backend call it once a day and do the usual thing.
> I do that with a backend that shuts down when idle and it "just works".

The issue with the new command line parser is that in an attempt to 
retain consistency the actual parser method is ignorant of what kind of 
data is expected on the command line.  It naively searches for options 
starting with '--', handling them independently.  Since quotations are 
stripped by the shell application, the parser has no way of knowing that 
'--daily' should be handled different from '--graboptions'.  Also, 
'"--days 1"' would be treated incorrectly as a option string, rather 
than an option and value.

The likely solution will be to remove the --graboptions option in favor 
of the somewhat standard convention for command line passthrough.  
Anything after a '--' string would be passed directly to the grabber 
without processing.  While this would break all existing uses, the only 
existing uses would be a limited subset of users, with screwy 
configurations like Shepherd wants to force.  The alternative would be 
to drop the option all together, requiring the grabber, or in lieu of 
that and wrapper around it, to just 'do the right thing'.

More information about the mythtv-dev mailing list