Unable to upgrade above 1.108. Weird console errors

I have a large angular application using Cesium js as rendering engine for maps.
The currently installed version of cesium is 1.108. When trying to upgrade I get weird errors in the console on startup of the application. This happens on every version above 1.108. In some versions (particularly 1.109) I see the dreaded “Rendering has stopped” message over the map, in others (particularly 1.111) only the errors in the console appear. Although the map image appears normally, other elements of the application (stuff that needs to be displayed on top of the map) doesn’t load, apparently the application runs into some error that prevents it from actually using the cesium Viewer.
The errors in the console amount to not being able to access local resources such as approximateTerrainHeights.json, Textures/SkyBox/tycho2t3_80_px.jpg and several other related files.
What is weird is that the path where these files are located differs from the path displayed in the console. For instance: the browser is looking for:

node_modules/@cesium/engine/Source/Core/Assets/approximateTerrainHeights.json

but the file actually exists in:

node_modules/@cesium/engine/Source/Assets/approximateTerrainHeights.json

The Assets directory is not a subdirectory of Core, but exists on the same level.
After the errors mentioned above, some errors follow which I believe to be specific to my application, but reveal no information on what actually went wrong.
None of this occurs with version 1.108. I’ve looked at the changelog (https://github.com/CesiumGS/cesium/blob/main/CHANGES.md) but I can’t find anything helpful there.
This issue is preventing me from updating to the current version of CesiumJs.

To answer my own question (and in case someone runs into the same issue): we were able to solve this by fixing the dependencies of our Angular application.
Previously we had been unable to get the locally built cesium to run properly inside our application, we would get lots of resource not found errors. As a workaround we added a link to the cesium CDN. That fixed our immediate issues and worked nicely up to version 1.108. But we also left the dependency on cesium in the project since we needed the typescript typings and intellisense help. (We knew we had to fix this some day, but other priorities, oh well, you know how it goes). After the problems described above surfaced, I was able to fix our angular dependencies thanks to this project:

Now cesium gets built properly with our project, the CDN is no longer needed and everything runs smoothly also in v 1.111.

1 Like

Hey @markchagers :wave: I am glad that our example application helped you :grinning: Let me know if you run into any weird issues with Angular and Cesium in the future!

1 Like