Cesium + nginx/http2: intermittent fail to load js files

cesium 1.74, debian buster, nginx/1.19.2/ Chrome Version 88.0.4302.0 on MacOS here
nginx config pretty standard as per https://www.digitalocean.com/community/tools/nginx

  • serving via ‘npm start’ / node works fine
  • serving via nginx/HTTP 1.1 works fine
  • serving via nginx/HTTP2 intermittently fails to load some js files

example error message when loading sandcastle:

> Error loading https://stiwoll.mah.priv.at/sandbox/cesium/Apps/Sandcastle/load-cesium-es6.js
> Make sure Cesium is built, see the Contributor's Guide for details.

Chrome DevTools console log:

Drilling down on one of these failed files (eg load-cesium-es6.js) in the Headers network panel yields:

So it looks nginx served the file just fine, but Chrome for some reason failed to digest it properly

downgrading nginx to http from http2 (deleting ‘http2’ keyword from ‘listen’ directive) consistently fixes the error, but loading times are significantly longer

I’m pretty sure this is not specifically a cesium issue - nevertheless asking here if some telemetry on this is already known

this smells similar in nature - could be caching related

happy to dig further/post configs as directed

thanks in advance,


Check out our distro, it might help out with this problem.