API Compatibility Issues
Closed this issue · 1 comments
Dear developers,
We have recently developed a state-of-the-art static analysis tool for uncovering API compatibility issues in Android apps. Applying this tool to open source apps on F-droid, we have exposed a few instances of compatibility issues and submitting them to development teams for a fix.
For your app, we have found that this project has accessed the following APIs which are available only on an API level higher than the declared minSdkVersion and which are accessed without proper protection. In other words, if those APIs get called at runtime, it will trigger a NoSuchMethodError and thus result in a crash of the running application.
<android.widget.SearchView: void setOnQueryTextListener(android.widget.SearchView.OnQueryTextListener)>:[11,25]
<android.app.Activity: android.app.ActionBar getActionBar()>:[11,25]
<android.widget.SearchView: void setQuery(java.lang.CharSequence,boolean)>:[11,25]
<android.view.MotionEvent: int getPointerCount()>:[5,25]
<android.view.MenuItem: android.view.MenuItem setActionView(android.view.View)>:[11,25]
<android.widget.SearchView: void setOnCloseListener(android.widget.SearchView.OnCloseListener)>:[11,25]
<android.view.inputmethod.InputMethodManager: boolean hideSoftInputFromWindow(android.os.IBinder,int)>:[3,25]
<android.widget.SearchView.OnQueryTextListener: boolean onQueryTextChange(java.lang.String)>:[11,25]
<android.widget.SearchView: void setIconified(boolean)>:[11,25]
<android.os.AsyncTask: void ()>:[3,25]
<android.app.ActionBar: void setDisplayHomeAsUpEnabled(boolean)>:[11,25]
<android.view.MenuItem: void setShowAsAction(int)>:[11,25]
<android.view.MotionEvent: float getX(int)>:[5,25]
<android.app.Activity: void invalidateOptionsMenu()>:[11,25]
<android.view.MotionEvent: float getY(int)>:[5,25]
<android.app.ActivityManager: int getMemoryClass()>:[5,25]
Note that, because of the nature of the static analysis, we cannot confirm whether the flagged APIs would actually be called at runtime (e.g., unreachable code). However, we still believe that those APIs, which may cause compatibility issues, should not be accessed or at least be accessed with proper protections.
In addition to the aforementioned APIs (i.e., backward-compatibility), which could cause app crashes if accessed, we have also identified that this project has also accessed some APIs that have been removed from the latest public SDK, making the app possibly suffer from forward-compatibility issues.
NONE
We would be very much appreciated if you can acknowledge to us that those reported APIs are indeed problematic for the project’s long-term stability. please let us know if you need any more information relating to this issue report.
Thanks for the report. I track live crashes using reports in PlayStore. Either there are no such devices anymore, or the invocations are carefully guarded or people don't bother reporting.