title: How to detect if a located element is indeed on top and clickable using uiautomator2?
body: <pre><code>import uiautomator2
  device = uiautomator2.connect()
  elem = device(resourceId=&quot;com.someapp.droid.full:id/publisher_content_row&quot;,
              className=&quot;android.view.ViewGroup&quot;)
  elem.click(5)
  </code></pre>
  <p>It is often clicking the bottom-bar or the top bar as the selected item might be hidden behind them occasionally.</p>