-
Notifications
You must be signed in to change notification settings - Fork 25
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
Module util could not be found #120
Comments
Hi @MaTiAtSIE I'm not sure how theia changes things, but here's some notes about using webpack: #116 (comment) |
I have the same error. I followed #116. Locally it works, but when I invoke my AWS Lambda, it fails. After updating the webpack, I receive this error:
|
@wilwade Thanks for the hint. I extended my webpack.config.js script with
which compiles. After starting my application, I get directly the same error as @mpoferl and others in #116 : 'TypeError: Cannot read properties of undefined (reading 'webkitRequestFileSystem')'. |
We tested another alternative: Using brotli-wasm v2.0.1 as drop in replacement of wasm-brotli.
This worked for us. No changes in the webpack configuration were required. |
@MaTiAtSIE that looks like a clean update to me as well. Made a PR #123 and try to get it merged and a release out today. |
Per @ MaTiAtSIE via #120 (comment) Switch from the older, non-maintained [wasm-brotli](https://github.com/dfrankland/wasm-brotli) to the newer and maintained [brotli-wasm](https://github.com/httptoolkit/brotli-wasm). Drop in swap, all tests still pass. Closes #120
@MaTiAtSIE v1.6.2 is out with the suggested fix. |
Steps to reproduce
Setup:
Typescript == 4.9.5
node == 20.0.0
theia == 1.45.0
@dsnp/parquetjs == 1.6.0
Webpack == 5.90.3
I develop a theia application where I added @dsnp/parquetjs to a theia extension with
After that, @dsnp/parquetjs version 1.6.0 was added. I implemented the ParquetReader example in the backend. The build was conducted without any error. However, at runtime, I get an error in the backend saying that the module util could not be imported from wasm_brotli_nodejs.
To fix this, we make the following changes in wasm_brotli_nodejs.js:
Subsequently, we get another runtime error that wasm_brotli_nodejs_bg.wasm could not be found in applications\theia-browser\lib\backend. This error could be solved by copying the file into the directory. As an alternative, it was also possible to solve this issue with some modifications in wasm_brotli_nodejs_bg.js.
The question is: What has to be done to consume @dsnp/parquetjs without these modifications from our node app with webpack 5?
The text was updated successfully, but these errors were encountered: