AnsweredAssumed Answered

[ElevayionLayer] Subclassing BaseElevationLayer generates console.error() message

Question asked by victorberchet on Sep 23, 2020

My app subclasses the BaseElevationLayer to add altitude exaggeration exactly as in the sandbox example.

 

If first notice the console errors using my app but they are reproducible with the sandbox example provided you spend some time navigating to places out of the cache (try zoom-in / zoom-out).

 

You should see some errors in the javascript console:

SceneView.js:3567 Tile 14,5750,8403 layer 0/0 error [tile-map:tile-unavailable]: Tile is not available
SceneView.js:3567 Tile 14,5749,8403 layer 0/0 error [tile-map:tile-unavailable]: Tile is not available
SceneView.js:3567 Tile 15,11500,16806 layer 0/0 error [tile-map:tile-unavailable]: Tile is not available
[...]

I end up getting a lot of those.

 

They originate from the following code (in the ArcGIS API):

 

 b.prototype.dataMissing = function(a, b, c) {
   c.notInTilemap || console.error("Tile " + this.lij.toString() + " layer " + b + "/" + a + " error " + c);
   a = this.layerInfo[b][a];
   a.dataMissing = !0;
   for (b = 0; b < a.waitingAgents.length; b++)
   a.waitingAgents[b].dataMissing();
   a.waitingAgents.length = 0;
   this._updateMemoryUsed()
}

I haven't investigated further as tracing minified code is not fun !

 

My guess would be that this code is in the BaseElevationLayer but is not in the actual ElevationLayer (as errors are not generated with a vanilla ElevationLayer).

 

It would be super nice to have a way to disable those errors as they look messy in the javascript console.

It's probably low priority as it doesn't seem to prevent everything else to work as expected.

 

Thanks !

Outcomes