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

Layout benchmark broken #1254

Closed
wipfli opened this issue May 28, 2022 · 4 comments · Fixed by #1297
Closed

Layout benchmark broken #1254

wipfli opened this issue May 28, 2022 · 4 comments · Fixed by #1297
Labels

Comments

@wipfli
Copy link
Contributor

wipfli commented May 28, 2022

The Layout benchmark seems to be broken. Thanks @ambientlight for pointing this out.

Steps to reproduce the problem:

npm ci
npm run generate-typings && npm run build-prod && npm run build-csp && npm run build-dev && npm run build-css && npm run build-style-spec

npm run start-bench

(maybe I should put all the build commands in a build-all?)

Then open your browser, got to http://localhost:9966/bench/versions and wait for the Layout benchmark to show up (side note, one should be able to open http://localhost:9966/bench/versions?compare=main#Layout to see only the layout benchmark, but this is broken, too works on a clean install). Open the browser console and you will find the following error message

style.ts:503 Uncaught TypeError: Cannot read properties of undefined (reading 'updateElevation')
    at oe.setTerrain (style.ts:503:32)
    at oe._load (style.ts:287:14)
    at style.ts:242:18

Going forward, we should really refactor the benchmarks and run them in CI. This would maybe not give significant numbers, but at least we could see if the benchmarks still work.

@wipfli
Copy link
Contributor Author

wipfli commented May 28, 2022

The above error message is from chrome. Firefox says:

Uncaught TypeError: this.map.transform is undefined
    setTerrain style.ts:503
    _load style.ts:287
    _request style.ts:242

@wipfli
Copy link
Contributor Author

wipfli commented Jun 5, 2022

#1238 mentions that the following benchmarks are bad: Layout, WorkerTransfer, SymbolLayout, HillshadeLoad

@wipfli
Copy link
Contributor Author

wipfli commented Jun 5, 2022

HilshadeLoad works for me. The others (Layout, WorkerTransfer, SymbolLayout) all show the same console error:

style.ts:505 Uncaught TypeError: Cannot read properties of undefined (reading 'updateElevation')
    at oe.setTerrain (style.ts:505:32)
    at oe._load (style.ts:287:14)
    at style.ts:242:18

@wipfli
Copy link
Contributor Author

wipfli commented Jun 5, 2022

They are the only three benchmarks which use this.parser.parseTile() inside the setup function.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
1 participant