title: android studio: always getting Failure [INSTALL_FAILED_DEXOPT]
body: <p>I am getting start with android studio and I success in running my application on the emulator,<br>
  while after sometimes of successful and when I want to run my application again,<br>
  I get the error<br>
  Failure [INSTALL_FAILED_DEXOPT]<br>
  and ask me to uninstall my application in the emulator.    </p>
  
  <p>After clicking OK, I get the error<br>
  Unknown failure</p>
  
  <p>And when I try to click run application again, I get another error<br>
  Failure [INSTALL_FAILED_UID_CHANGED]  </p>
  
  <p>I can successful solve my program by rebuilt project and manually removing the package in /data/data and /data/local/tmp.<br>
  But the problem exist again and again after a few run.<br>
  What I should do to stop this problem as it make my debugging extremely difficult.  </p>
  
  <p>Here are the error message I get:  </p>
  
  <pre><code>Waiting for device.
  Target device: Nexus_4_API_19 [emulator-5554]
  Uploading file
      local path: C:\Users\brian_000\AndroidStudioProjects\MyApplication\app\build\outputs\apk\app-debug.apk
      remote path: /data/local/tmp/com.example.brian.myapp
  Installing com.example.brian.myapp
  DEVICE SHELL COMMAND: pm install -r "/data/local/tmp/com.example.brian.myapp"
  pkg: /data/local/tmp/com.example.brian.myapp
  Failure [INSTALL_FAILED_DEXOPT]
  
  
  DEVICE SHELL COMMAND: pm uninstall com.example.brian.myapp
  DEVICE SHELL COMMAND: pm install -r "/data/local/tmp/com.example.brian.myapp"
  pkg: /data/local/tmp/com.example.brian.myapp
  Failure [INSTALL_FAILED_DEXOPT]
  
  
  DEVICE SHELL COMMAND: pm uninstall com.example.brian.myapp
  Unknown failure
  </code></pre>