Forum Archive

Unable to run python script

zeitgeist

Has anyone else seen a problem with Pythonista 1.4 not running a script? It does not report any error or output in the console (even if I have a print statement early on).

As far as I can figure out, it happens when there is a syntax error in the script, but it does not report the syntax error, so I can't easily find out where it is.

If I copy the script to my Mac, find and fix the problem and then copy back to my iPad, the script runs again!

I am not sure what originally caused the problem with identifying syntax errors as other scripts are OK, but it is very annoying.

brumm

Hello zeitgeist, do you wrote your script with Pythonista or another app? Do you create it with the "Empty Script" option? Maybe you like to show your code?

ccc

Yes. I usually find this when parentheses are unbalanced. For instance, the following silently fails to do anything at all:

print('Hello')
i = (