Cesium: missing ThirdParty/pako_inflate

Created on 5 Jun 2017  Â·  19Comments  Â·  Source: CesiumGS/cesium

After updating to 1.34 I get kind of similar error to #5278 (probably somewhere else than before):

Cesium missing ThirdParty/pako_inflate

when using unminified version, full error:

Cesium.js:337 Uncaught Error: Cesium missing ThirdParty/pako_inflate
    at main (Cesium.js:337)
    at callDep (Cesium.js:199)
    at main (Cesium.js:332)
    at req (Cesium.js:406)
    at Cesium.js:206875
    at Object.<anonymous> (Cesium.js:206886)
    at Object.<anonymous> (Cesium.js:206886)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (cesium.service.ts:1)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (help.component.ts:11)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (index.ts:1)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (app.routes.ts:2)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (app.component.ts:35)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (index.ts:1)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (main.browser.ts:1)
    at __webpack_require__ (bootstrap 416caff…:688)
    at fn (bootstrap 416caff…:109)
    at Object.<anonymous> (cesiumHeatmapRight.js:360)
    at __webpack_require__ (bootstrap 416caff…:688)
    at bootstrap 416caff…:789
    at main.bundle.js:794

I'm using angular + webpack.

category - tooling priority - high type - bug

All 19 comments

I've been successfully using Webpack by including Source/Cesium.js instead of Build/Cesium/Cesium.js (or Build/CesiumUnminified/Cesium.js). I'm still a Webpack newbie; ideally I'd like to just use the pre-built Cesium and not have Webpack bother trying to modularize it, but at least this way it works at all.

I got the same problem so I use 1.31 version.

Hi guys, I'm experiencing a similar issue with webpacking Cesium due to issues with loading pako_inflate/decodeGoogleEarthEnterprisePacket. I circumvent the issue by building/combining the Cesium source after deleting those 2 files to remove their dependencies, but I'm unsure what the ramifications of that might be. Is there possibly a solution to this issue? Oh and thanks for fixing the jsep issue, that was another problem when webpacking.

@jason-crow you're having that issue with Cesium 1.35? @ggetz do you want to look at this?

@hpinkos , Yes, technically i'm using the 3d-tiles-vector branch, but it appears to be up to date with master. , the version is 1.35.2

Sure @hpinkos, I will take a look at this soon.

@EvaldasVasiliauskas or @jason-crow could you post your webpack configuration and directory structure to help me reproduce this? I am unable to reproduce this using the example from the blog post and Build/CesiumUnminified/Cesium.js

I have also encountered this problem when using Cesium 1.35 ,but 1.31 does not. Here is my repository https://github.com/543802360/express-webpack-cesium, Cesium 1.31 works well

I have the same problem using react with webpack. Using 1.31 and 1.32 works fine, but with 1.35 and 1.36 i get this same error whether using Build/CesiumUnminified/Cesium.js or Build/Cesium/Cesium.js

hello, is there any WA meanwhile? Thanks

We're working on a solution for the webpack issues soon, in the meantime you may have some luck using Source/Cesium.js instead of the built version.

This should be addressed by our recommended webpack configuration https://cesiumjs.org/tutorials/cesium-and-webpack/

cesium is making my devtool pretty slow ... unacceptable
is there a pre built version, I dont want webpack handle the build process of cesium

@magicdawn the built release is available for download on our website: https://cesiumjs.org/downloads/
or through NPM, it can be found in node_modules/cesium/Build/Cesium

In the future, please ask questions like this on our forum: https://groups.google.com/forum/?hl=en#!forum/cesium-dev
The forum has much higher traffic so it is more likely someone will see your question and be able to help. It's easy for us to miss your question if you comment on a closed issue.

@magicdawn more specifically, the tutorial I linked to above https://cesiumjs.org/tutorials/cesium-and-webpack/ will not only provide you an optimal webpack environment for Cesium, but will cover how to sue the built version with it for fast iteration.

Oh I use webpack required cesium/Build/Cesium/Cesium.js and tell webpack not to parse the built js file. and it throw error like this issue.

After I copy file and load cesium using <script> tag, it worked.

Thanks

I think this is linked elsewhere, but if anybody is still interested in "managing" Cesium via Webpack without the time sink of re-building it all the time, I was able to make my own Webpack DLL based on this writeup. It's a bit of a time investment but it gives you more control over the final output.

@magicdawn Hi, please create gist of your webpack config.. r u using webpack 3.* +?

@js2me if you have webpack questions, our Cesium and Webpack tutorial might help you: https://cesiumjs.org/tutorials/cesium-and-webpack/

Otherwise, please ask any questions you have on our forum: https://groups.google.com/forum/?hl=en#!forum/cesium-dev

Was this page helpful?
0 / 5 - 0 ratings