java.lang.NullPointerException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • TiDownloadManager doesn't seem to properly handle redirects on Android Lollipop. This is the exception I get: {code} ERROR] TiDownloadManager: (pool-4-thread-1) [916,916] Exception downloading https://graph.facebook.com/100008778152788/picture?width=200&height=200 [ERROR] TiDownloadManager: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.startsWith(java.lang.String)' on a null object reference [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.StatusLine.<init>(StatusLine.java:24) [ERROR] TiDownloadManager: at com.android.okhttp.Response$Builder.statusLine(Response.java:419) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.JavaApiConverter.createOkResponse(JavaApiConverter.java:116) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.ResponseCacheAdapter.get(ResponseCacheAdapter.java:53) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:190) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:373) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:323) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:190) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:25) [ERROR] TiDownloadManager: at java.net.URL.openStream(URL.java:470) [ERROR] TiDownloadManager: at org.appcelerator.titanium.util.TiDownloadManager$DownloadJob.run(TiDownloadManager.java:135) [ERROR] TiDownloadManager: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) [ERROR] TiDownloadManager: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) [ERROR] TiDownloadManager: at java.lang.Thread.run(Thread.java:818) {code} Attached you can find a single window application in which two image views are used to display remote images. The second of the two uses some facebook redirect to get the actual image url, and TiDownloadManager crashes while fetching the data.
    via by Matteo Landi,
  • TiDownloadManager doesn't seem to properly handle redirects on Android Lollipop. This is the exception I get: {code} ERROR] TiDownloadManager: (pool-4-thread-1) [916,916] Exception downloading https://graph.facebook.com/100008778152788/picture?width=200&height=200 [ERROR] TiDownloadManager: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.startsWith(java.lang.String)' on a null object reference [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.StatusLine.<init>(StatusLine.java:24) [ERROR] TiDownloadManager: at com.android.okhttp.Response$Builder.statusLine(Response.java:419) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.JavaApiConverter.createOkResponse(JavaApiConverter.java:116) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.ResponseCacheAdapter.get(ResponseCacheAdapter.java:53) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:190) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:373) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:323) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:190) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210) [ERROR] TiDownloadManager: at com.android.okhttp.internal.http.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:25) [ERROR] TiDownloadManager: at java.net.URL.openStream(URL.java:470) [ERROR] TiDownloadManager: at org.appcelerator.titanium.util.TiDownloadManager$DownloadJob.run(TiDownloadManager.java:135) [ERROR] TiDownloadManager: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) [ERROR] TiDownloadManager: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) [ERROR] TiDownloadManager: at java.lang.Thread.run(Thread.java:818) {code} Attached you can find a single window application in which two image views are used to display remote images. The second of the two uses some facebook redirect to get the actual image url, and TiDownloadManager crashes while fetching the data.
    via by Matteo Landi,
  • GitHub comment 37#108246488
    via GitHub by jdupuis
    ,
  • h5.Description: 1. Create a basic map app for android. 2. Build it for android 5.0 device/emulator. h5.Actual Result: 1. We do not see any maps just the grid. 2. We also get the errors below in the console: {code} [DEBUG] : REQUEST: Connection opened to:https://clients4.google.com/glm/mmap/api [DEBUG] : REQUEST: Open Connection [DEBUG] : REQUEST: DRD(462): 62|15|7|108 [DEBUG] : REQUEST: Close [DEBUG] : REQUEST: Error processing: com.google.maps.api.android.lib6.b.d@2454d051 not retrying [DEBUG] : REQUEST: Retrying: com.google.maps.api.android.lib6.b.j@1beb77e [DEBUG] : REQUEST: Retrying: com.google.maps.api.android.lib6.b.v@390b4df [DEBUG] : REQUEST: Retrying: com.google.maps.api.android.lib6.gmm6.m.af@32c684fc [ERROR] : REQUEST: ERROR [ERROR] : REQUEST: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.startsWith(java.lang.String)' on a null object reference [ERROR] : REQUEST: at com.android.okhttp.internal.http.StatusLine.<init>(StatusLine.java:24) [ERROR] : REQUEST: at com.android.okhttp.Response$Builder.statusLine(Response.java:419) [ERROR] : REQUEST: at com.android.okhttp.internal.http.JavaApiConverter.createOkResponse(JavaApiConverter.java:116) [ERROR] : REQUEST: at com.android.okhttp.internal.http.ResponseCacheAdapter.get(ResponseCacheAdapter.java:53) [ERROR] : REQUEST: at com.android.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:190) [ERROR] : REQUEST: at com.android.okhttp.internal.http.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:373) [ERROR] : REQUEST: at com.android.okhttp.internal.http.HttpURLConnectionImpl.connect(HttpURLConnectionImpl.java:106) [ERROR] : REQUEST: at com.android.okhttp.internal.http.HttpURLConnectionImpl.getOutputStream(HttpURLConnectionImpl.java:208) [ERROR] : REQUEST: at com.android.okhttp.internal.http.DelegatingHttpsURLConnection.getOutputStream(DelegatingHttpsURLConnection.java:218) [ERROR] : REQUEST: at com.android.okhttp.internal.http.HttpsURLConnectionImpl.getOutputStream(HttpsURLConnectionImpl.java:25) [ERROR] : REQUEST: at com.google.maps.api.android.lib6.b.l.run(Unknown Source) [ERROR] : REQUEST: at java.lang.Thread.run(Thread.java:818) {code} h5.Expected Results: 1. Maps should be displayed properly & we should not get any errors in the console.
    via by Lokesh Choudhary,
    • java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.startsWith(java.lang.String)' on a null object reference at com.android.okhttp.internal.http.StatusLine.<init>(StatusLine.java:24) at com.android.okhttp.Response$Builder.statusLine(Response.java:419) at com.android.okhttp.internal.http.JavaApiConverter.createOkResponse(JavaApiConverter.java:116) at com.android.okhttp.internal.http.ResponseCacheAdapter.get(ResponseCacheAdapter.java:53) at com.android.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:190) at com.android.okhttp.internal.http.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:373) at com.android.okhttp.internal.http.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:323) at com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:190) at com.android.okhttp.internal.http.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210) at com.android.okhttp.internal.http.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:25) at java.net.URL.openStream(URL.java:470) at org.appcelerator.titanium.util.TiDownloadManager$DownloadJob.run(TiDownloadManager.java:135) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) at java.lang.Thread.run(Thread.java:818)

    Users with the same issue

    Unknown visitor1 times, last one,