visgl / loaders.gl

Loaders for big data visualization. Website:
https://loaders.gl
Other
713 stars 193 forks source link

Tracker: v3.0 Release checklist #772

Closed ibgreen closed 1 year ago

ibgreen commented 4 years ago
kylebarron commented 4 years ago
  • MVTLoader tests fail under Safari

It's this test that's failing.

https://github.com/visgl/loaders.gl/blob/112b16c544debdebaf17dfefad9814107e9e6283/modules/mvt/test/mvt-loader.spec.js#L125-L144

Specifically it looks like there are some float precision errors in Safari. The created geojson is expected to match this file. In this screenshot the first console.log is the geojson decoded from MVT, and the latter is what's expected to match. There are several such differences. image

So I'd guess a good solution would be to use some epsilon instead of strict equality for float checking here?

ibgreen commented 4 years ago

Thanks for investigating, this makes sense. It is not really a bug then, but nevertheless, it would be good to get a clean test run.

There is a test/utils/tape-assertions that exports tapeEqualsEpsilon(t, value, expected, epsilon, message),