Page 1 of 1

Tester failed after upgrade from 0.x to 1.x

Posted: Wed Sep 24, 2008 5:16 pm
by paullanders
Hi Dave.

After upgrading from 0.x to 1.x, I noted that test-threaded.php failed with the following errors:

./test-threaded.php: line 1: ?php: No such file or directory
./test-threaded.php: line 2: syntax error near unexpected token `"include.php"'
./test-threaded.php: line 2: `require("include.php");'


The problem was that test-threaded.php was missing it's very first line:

#!/usr/bin/php -q

Paul :)

Re: Tester failed after upgrade from 0.x to 1.x

Posted: Wed Sep 24, 2008 5:45 pm
by dave
Hi Paul,

Ah! Perhaps the documentation should have been a bit clearer... I'll have a look.

In v1 the files change from test-threaded.sh to test-threaded.php and no longer have the shebang line. This is because the shebang line requires a specific directory location and some people had problems because their PHP binary wasn't in the same place (there is an alternative program you can use but it doesn't work with parameters).

So... the idea in v1 is that you php test-threaded.php which means you are running the PHP binary from your script and passing it the file to run.

To keep everything working there is (or rather, should be) still a test-threaded.sh which will continue to work in exactly the same way as before - it just has the shebang line and then includes test.threaded.php in the code.

So if you just either change your start script to do a php test-threaded.php or point it back to ./test-threaded.sh all should be ok.

Hope that helps,

Regards,

Dave.