# DailyMail v1.01.02



## PhilG (Jan 15, 2002)

Quick question

I am trying to upgrade my DailyMail to thsi latest(?) version but when I run it, even with debug level 3, all I get is

couldn't read file "
": no such file or directory

I suspect I've made a configuration error, but as I don't even get any debug output(!) it's hard to figure out where and what

Is there some switch I can set (or command I can add to the script) that will trace the execution of ALL statements so I can see where it's dieing?

Many thanks

Phil G


----------



## yungee (Dec 29, 2002)

You don't have any spaces in folder or filenames do you?

Unix _hates_ spaces!

I always stick to lowercase and underscores only on the Tivo.


----------



## PhilG (Jan 15, 2002)

Nope (not that I know of anyway - that's not to say I might not have added a spurious space somewhere in the config file, it does go on rather!)


----------



## yungee (Dec 29, 2002)

Did you edit it on a PC or on the box? Maybe the DOS CR/LF line endings problem if the former?

Seems odd ... perhaps post the config here? Without your mailserver details and passwords etc. of course!


----------



## PhilG (Jan 15, 2002)

I was trying to avoid that level of help 

It's all edited on the pc, but with a Unix friendly editor that doesn't add all those "added no-value" Windows features!

If I can just get a trace of the script as it executes, it'll all become blindingly obvious (I think)


----------



## PhilG (Jan 15, 2002)

What I do find rather worrying is that the scrip STARTS with 

###########################################################################################################
## MAIN CODE

## initial logging text
puts ""
puts ""
puts "------welcome to the jazzed dailymail program - v$software_version ($software_release_date) - starting"

and I don't even get THAT written out

Hmmm

Perhaps something else is wrong

I'm sure Tivo is trying to execute SOMETHING as I definately don't get the "xxxxx not found" message that you get when you miss-spell things!

Does Tivos Unix attempt to "compile" scripts before it executes them and catches stupidities like this before execution starts?

If so, I'll need to dig a LOT deeper

Anonymous-ised version of my config file attached


----------



## PhilG (Jan 15, 2002)

Hmm - well, I THOUGHT I'd attached it

Let's try again

 Much better


----------



## yungee (Dec 29, 2002)

Just a quick sanity check ... it's called "dailymail.cfg" on your Tivo, not "dailymail..cfg" or "dailymail..cfg.txt"?

Also, just trying this myself and I noticed my FTP client (FlashFXP) left to it's own devices treats .tcl files as ASCII which means it adds the CR/LF when it uploads files. I noticed the .tcl files grew in size when transferred!

Changing this to binary mode made it work fine.

... a lot later ... after finding a BASE64 encoder! 

Mine ran for a while then died as I don't have TivoWeb installed on that Tivo yet. To late to get going on that tonight I'm afraid. However I did get NO console messages, and a decent chunk of a logfile:

bash-2.02# cat /var/log/dailymail_jazz.log

------welcome to the jazzed dailymail program - v1.01 (02 May 2006) - starting
------the debug level is set at >>3<<
------started at 23:15:40 (debugging times specified in gmt)

23:15:40-compiled image name list: >>tivologo.jpg tivo-ok.jpg tivo-broken.jpg 

... etc for another 50 lines or so


----------



## yungee (Dec 29, 2002)

... even later still ... I did install TivoWeb as I couldn't go to bed with this unfinished!

I installed 1.9.4 of the standard version as TivoWebPlus 1.3.1 was shockingly unstable on my (currently dead!  ) other Tivo.

With the Daily Mail Jazz modules copied over, I ran it from within the web interface as a test, and after a nail biting minute or so, everything worked fine.

It doesn't help you much I'm afraid Phil. I'll have another look at your config file now I've edited my own.


----------



## TCM2007 (Dec 25, 2006)

PhilG said:


> It's all edited on the pc, but with a Unix friendly editor that doesn't add all those "added no-value" Windows features!


Your FTP client will screw up the files with Windows CR/LFs unless you force it to binary however you edited them.

You get the file not found message as the first line of the script defines the shell to be used, and the extra line ending is interpreted as being part of the shell's filename.


----------



## yungee (Dec 29, 2002)

... and a little later still, hmm, your config file looks OK.

I think I've got it, and you'll kick yourself.

You need to run the shell script:

./dailymail_jazz

NOT the .tcl file

./dailymail_jazz.tcl

Running that directly gives me (near as dammit) the error you got:

bash-2.02# ./dailymail_jazz.tcl
": no such file or directory


----------



## Tony Hoyle (Apr 1, 2002)

dailymail looks like it's written on windows - there are CRLF's all over it.. that breaks the hashbang mechanism hence the extra script (which isn't needed really.. I never use it).

The quick fix is to remove the DOS line endings from the first line, which is the issue. You might as well remove them all though.

I have this short script in /var/hack/bin I call 'dos2unix':

#!/bin/sh
tr -d '\015' <$1 >/tmp/$$
mv /tmp/$$ $1

Then to de-DOSify something like dailymail you just run dos2unix over it, or simply:

for i in *; do dos2unix "$i"; done

(btw. don't do that in a directory with binaries in it...)

I tend to do that routinely with stuff anyway as editing windows files under unix is a pain when every line ends with a gratuituos ^M.


----------



## PhilG (Jan 15, 2002)

OK, THAT's forward progress!!

However, when I run /var/hack/dailymail/dailymail_jazz from a Telnet prompt, it then seems to be waiting for more input from the keyboard.

After waiting an AGE (and not wanting to hit CTRL-C!) I hit enter just to see, and sure enough it seemed to be waiting for me to enter something - so I took the bull by the horns and DID do a CTRL-C to terminate it

Sure enough it rebooted Tivo 

I assumed I should have seen SOME output??

PS ALL my transfers ARE done in binary


----------



## TCM2007 (Dec 25, 2006)

It does take a long time to run. Background it with & at the end to gte your prompt back.


----------



## PhilG (Jan 15, 2002)

The old version runs in 38 seconds (or so) - is this version really that much different?

Also, although debuglvl is 3, I saw NO output - not even the initial welcome text.....


----------



## yungee (Dec 29, 2002)

The new one takes a couple of minutes on my Tivo. I never ran a previous version so couldn't comment on any difference.

At debug 3 it produces no screen output but greater detail in the log.

Check the log ... /var/log/<something_obvious_that_I_can't_remember!>


----------



## PhilG (Jan 15, 2002)

It's /var/log/dailymail_jazz.log

It does seem to be progressing, however I do have one question

In the summary "ToDo" list, it appends lots of information after the program title. Most of it is self evident (length, size etc) but I also see

"SP2 EP5 NEW "

or

"SP2 PASS "

What do these mean? I've looked through the doc but it doesn't explain what these are

Thanks


----------



## yungee (Dec 29, 2002)

PhilG said:


> It's /var/log/dailymail_jazz.log
> 
> It does seem to be progressing


Blimey, how long does it take to run? How many shows and season passes etc. do you have?

Don't know the answer to your question, as mine doesn't seem to show that.

After the show name in "To Do" it shows:

[30 Min | 600 MB | 3.3 % | 119.1 Hrs]

Followed by some icons signifying: space added back, season pass, block.


----------



## PhilG (Jan 15, 2002)

I'm still looking at the remnants of this mornings run (before I can pluck up the courage to run it again!)

One example for a ToDo item says:

Figure Skating Fri 11:15 - 17:00 EURGB [352 Min | 3145 MB | 29.7 % | 183.0 Hrs] SP2 EP5 NEW 
ISU European Championships: Women's Short Programme - The women's short programme of the 98th ISU European Championships from Warsaw, Poland. Switzerland's Sarah Meier and Russia's Elena Sokolova are among the favourites for a medal.

I have graphics disabled

The [352 Min | 3145 MB | 29.7 % | 183.0 Hrs] bit all makes sense, but the SP2 EP5 NEW" has me foxed!


----------



## PhilG (Jan 15, 2002)

Slow progress

I am now looking at the TW extras that come with this version of DailyMail. One is a config file editor. This says "requires hackman" which I have, but the edit fails with

INTERNAL SERVER ERROR
--cut here--
action_editor '' 'set "filetobeedited" "/var/hack/dailymail/dailymail.cfg";'
can't read "edit": no such variable
while executing
"if {$edit == "Update"} {set filetobeedited $author\.draft
set filetitle $author}"
(procedure "::action_editor" line 10)
invoked from within
"::action_$action $chan $part $env"
("eval" body line 1)
invoked from within
"eval {::action_$action $chan $part $env}"
--cut here--

Seems to be looking for a command called "edit" - I don't have one

Is there a newer version of Hackman I should have? Mine is dated March 2005........

Thanks for all your help (and patience!)


----------



## Pete77 (Aug 1, 2006)

PhilG said:


> Is there a newer version of Hackman I should have? Mine is dated March 2005........
> 
> Thanks for all your help (and patience!)


The current version at www.tivohackman.com is v4.2.8 What version do you have?


----------



## TCM2007 (Dec 25, 2006)

PhilG said:


> The [352 Min | 3145 MB | 29.7 % | 183.0 Hrs] bit all makes sense, but the SP2 EP5 NEW" has me foxed!


Series 2 episode 5, new episode I'd guess.


----------



## PhilG (Jan 15, 2002)

TCM2007 said:


> Series 2 episode 5, new episode I'd guess.


You'd think so, but ALL programs are "SP2" so definately NOT Series 2

Next guess??


----------



## PhilG (Jan 15, 2002)

Now working OK - and if anyone is still following this, it turns out that SP2 means "Start Padding 2 minutes" and EP5 means "End Padding 5 minutes"

It's amazing how helpful the config file is when you read it properly!!!

The other flags are "WISH" for a wishlist autorecording and "NEW" for a new (forst run) recording

Good eh?


----------



## PhilG (Jan 15, 2002)

Just as a footnote to this, the time this script spends writing out debug information is quite surprising!

With DEBUG 3, my Dailymail runs for 15mins 20seconds
With DEBUG 2, it drops to 9mins 20seconds
and with DEBUG 1 it's a blinding 1min 12seconds!


----------



## ColinYounger (Aug 9, 2006)

Phil - good point. I've still got debug set to 3, even though it's working fine.

In short - move debug level down once you've got it working and only move it up if you have a problem.


----------

