what path does the run command use?

Asked by Jose Pablo Jimenez Velez

I'm trying some automation for a Android application
I want to send some adb commands to the devices connected by usb to my computer
I have adb on my path and I can run it form everywhere in my console
I tried adding the path of the adb executable to sys.path
But everytime I try to run adb command I get:
java.io.IOException: Cannot run program "adb": error=2, No such file or directory

Any ideas?

Question information

Language:
English Edit question
Status:
Answered
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
RaiMan (raimund-hocke) said :
#1

It seems, you are using Sikuli IDE or Sikuli from command line (since you are talking about sys.path)

sys.path has nothing to do with executables you try to run using the run() command. It is only for Sikuli (Jython/Python) to find modules or scripts that you want to import.

Try to use os.popen():

import os
os.popen(r'what you enter on the command line e.g. "c:\some-path\program" ')

Can you help with this problem?

Provide an answer of your own, or ask Jose Pablo Jimenez Velez for more information if necessary.

To post a message you must log in.