Python uiautomator doesn't works on MacOS <p>I wanna use uiautomator on Python to test some android apps. </p> <p>When I run this single code:</p> <pre><code>from uiautomator import device as d d.screen.on() </code></pre> <p>that show me the error below:</p> <pre><code>Traceback (most recent call last): File "cerrar.py", line 8, in &lt;module&gt; d.screen.on() File "/usr/local/lib/python2.7/site-packages/uiautomator/__init__.py", line 813, in on return devive_self.wakeup() </code></pre> <p>...</p> <pre><code>"$ANDROID_HOME environment not set." </code></pre> <p>I already have done the environment variables with:</p> <pre><code>vi ~/.bash_profile export ANDROID_HOME=/Applications/android-sdk-macosx export PATH=${PATH}:$ANDROID_HOME/tools:$ANDROID_HOME/platform-tools source ~/.bash_profile </code></pre> <p>Both ways android-sdk installed by android website or brew install, was tried it.</p> <p>if I run: <code>echo $ANDROID_HOME</code> or <code>adb devices</code> or <code>android</code></p> <p>Does works well...</p> <p>I can't understand what's going on whether the environment variables exists.</p> <p>My equip is: MacBook Pro Yosemite OS</p>