Question

I have started to use monkeyrunner or attempting. I have setup eclipse as described in this document http://forum.xda-developers.com/showthread.php?t=2566234 however every time I run my script I get the following error.

Can't open specified script file Usage: monkeyrunner [options] SCRIPT_FILE

-s      MonkeyServer IP Address.
-p      MonkeyServer TCP Port.
-v      MonkeyServer Logging level (ALL, FINEST, FINER, FINE, CONFIG, INFO, WARNING, SEVERE, OFF)

I have looked again and again and the only reason I see it not working is maybe due to my paths? If anyone has any information that could help it would be greatly appreciated.

Was it helpful?

Solution

You get this output when MonkeyRunner can not find the .py file that you want to run.

DONT forget to add the absolute path of your .py file so that MonkeyRunner knows where to find it. If you dont add the absolute path, MonkeyRunner looks for that file only in the same folder that MonkeyRunner itself resides.

EDIT: You can copy and paste the following into the arguments field of Eclipse External Run Configurations. It will pop-up a window so that you can select what file to run. It makes life easier!

${file_prompt:"Choose a File":${resource_loc}}
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top