KmlDemoActivity remote URL is broken · Issue #570 · googlemaps/android-maps-utils · GitHub
Skip to content

KmlDemoActivity remote URL is broken #570

Description

@barbeau

While looking at #558, I found that the URL used to demonstrate loading a remote KML file as a layer is broken (returns an HTTP 404).

Resource is kml_url in strings.xml, and here's the broken URL:
https://googlemaps.github.io/kml-samples/morekml/Polygons/Polygons.Google_Campus.kml

@jpoehnelt Do you know where this might have moved?

I think it may be the same file as the bundled campus.kml in the demo app raw directory, IIRC, if we can't find the original remote file.

Environment details

The current master branch at 80d9497 (0.6.2)

Steps to reproduce

  1. Run the demo app
  2. Tap on "KML LAYER OVERLAY" button at the bottom

What I expect to see

Polygons should load from the remote KML file and be shown on the map

What I actually see

No polygons load on the map - I just seem a blank, zoomed out world map (see screenshot below)

image

Stacktrace

2019-10-30 17:20:22.793 31875-32562/com.google.maps.android.utils.demo W/System.err: java.io.FileNotFoundException: https://googlemaps.github.io/kml-samples/morekml/Polygons/Polygons.Google_Campus.kml
2019-10-30 17:20:22.796 31875-32562/com.google.maps.android.utils.demo W/System.err:     at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:251)
2019-10-30 17:20:22.796 31875-32562/com.google.maps.android.utils.demo W/System.err:     at com.android.okhttp.internal.huc.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210)
2019-10-30 17:20:22.796 31875-32562/com.google.maps.android.utils.demo W/System.err:     at com.android.okhttp.internal.huc.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:26)
2019-10-30 17:20:22.796 31875-32562/com.google.maps.android.utils.demo W/System.err:     at java.net.URL.openStream(URL.java:1073)
2019-10-30 17:20:22.796 31875-32562/com.google.maps.android.utils.demo W/System.err:     at com.google.maps.android.utils.demo.KmlDemoActivity$DownloadKmlFile.doInBackground(KmlDemoActivity.java:91)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at com.google.maps.android.utils.demo.KmlDemoActivity$DownloadKmlFile.doInBackground(KmlDemoActivity.java:82)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at android.os.AsyncTask$2.call(AsyncTask.java:333)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:245)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
2019-10-30 17:20:22.797 31875-32562/com.google.maps.android.utils.demo W/System.err:     at java.lang.Thread.run(Thread.java:764)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err: java.lang.NullPointerException: Attempt to get length of null array
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at java.io.ByteArrayInputStream.<init>(ByteArrayInputStream.java:106)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at com.google.maps.android.utils.demo.KmlDemoActivity$DownloadKmlFile.onPostExecute(KmlDemoActivity.java:108)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at com.google.maps.android.utils.demo.KmlDemoActivity$DownloadKmlFile.onPostExecute(KmlDemoActivity.java:82)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at android.os.AsyncTask.finish(AsyncTask.java:695)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at android.os.AsyncTask.access$600(AsyncTask.java:180)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:712)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:106)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at android.os.Looper.loop(Looper.java:214)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at android.app.ActivityThread.main(ActivityThread.java:7050)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at java.lang.reflect.Method.invoke(Native Method)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
2019-10-30 17:20:22.801 31875-31875/com.google.maps.android.utils.demo W/System.err:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:964)

Metadata

Metadata

Assignees

No one assigned

    Labels

    priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions