Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't suppress useful errors #4912

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/ui/map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@
import {ITransform} from '../geo/transform_interface';
import {ICameraHelper} from '../geo/projection/camera_helper';
import {MercatorCameraHelper} from '../geo/projection/mercator_camera_helper';
import {isAbortError} from '../util/abort_error';

const version = packageJSON.version;

Expand Down Expand Up @@ -3192,7 +3193,7 @@

// update terrain stuff
if (this.terrain) {
this.terrain.sourceCache.update(this.transform, this.terrain);

Check failure on line 3196 in src/ui/map.ts

View workflow job for this annotation

GitHub Actions / Unit tests and Coverage

marker › Marker changes opacity behind terrain and when terrain is removed

TypeError: Cannot read properties of undefined (reading 'update') at Map._render (src/ui/map.ts:3196:38) at src/ui/map.ts:3344:22

Check failure on line 3196 in src/ui/map.ts

View workflow job for this annotation

GitHub Actions / Unit tests and Coverage

marker › Removes an open popup when going behind 3d terrain

TypeError: Cannot read properties of undefined (reading 'update') at Map._render (src/ui/map.ts:3196:38) at src/ui/map.ts:3344:22

Check failure on line 3196 in src/ui/map.ts

View workflow job for this annotation

GitHub Actions / Unit tests and Coverage

map events › projectiontransition event › projectiontransition events is fired when setProjection is called

TypeError: Cannot read properties of undefined (reading 'update') at Map._render (src/ui/map.ts:3196:38) at src/ui/map.ts:3344:22
this.transform.setMinElevationForCurrentTile(this.terrain.getMinTileElevationForLngLatZoom(this.transform.center, this.transform.tileZoom));
if (!this._elevationFreeze) {
this.transform.setElevation(this.terrain.getElevationForLngLatZoom(this.transform.center, this.transform.tileZoom));
Expand Down Expand Up @@ -3243,7 +3244,7 @@
// Even though `_styleDirty` and `_sourcesDirty` are reset in this
// method, synchronous events fired during Style#update or
// Style#_updateSources could have caused them to be set again.
const somethingDirty = this._sourcesDirty || this._styleDirty || this._placementDirty || this.style.projection.isRenderingDirty() || this.transform.isRenderingDirty();

Check failure on line 3247 in src/ui/map.ts

View workflow job for this annotation

GitHub Actions / Unit tests and Coverage

#getLayersOrder › returns ids of layers in the correct order

TypeError: Cannot read properties of undefined (reading 'projection') at Map._render (src/ui/map.ts:3247:109) at src/ui/map.ts:3344:22
if (somethingDirty || this._repaint) {
this.triggerRepaint();
} else if (!this.isMoving() && this.loaded()) {
Expand Down Expand Up @@ -3341,7 +3342,11 @@
PerformanceUtils.frame(paintStartTimeStamp);
this._frameRequest = null;
this._render(paintStartTimeStamp);
}).catch(() => {}); // ignore abort error
}).catch((error: Error) => {
if (!isAbortError(error)) {
throw error;
}
}); // ignore abort error
}
}

Expand Down
Loading