Comments (17)
Hmm, I'm trying to run it inside fresh docker container and getting these error. Anyway, thank you
It's strange, but locally with NODE_ENV=production everything is working. So something is missing in docker container
I managed to fix it via npm rebuild
from compression-webpack-plugin.
You tell me, you created the loose dependency.
from compression-webpack-plugin.
I't works when install [email protected]
, please use specific version!
from compression-webpack-plugin.
@Eightyplus Curious, why the version must be specific ? 😛
from compression-webpack-plugin.
kk I see now 😛 , I'm not the maintainer here, I will check why it is there in the first place and if it can be safetly removed, mom.
from compression-webpack-plugin.
We are struggeling with loose dependencies and migrating toward yarn to avoid this problem. But now and then it breaks because we haven't locked down all dependencies :)
from compression-webpack-plugin.
Setting it and the current range maybe also wrong :)
from compression-webpack-plugin.
I'm still trying to locate the exact problem, printing console.log(err)
before the error is thrown I get the following. It could indicate problems with another dependency, I'll keep you updated.
Error: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.14' not found (required by /usr/src/app/node_modules/node-zopfli/lib/binding/node-v51-linux-x64/zopfli.node)
at Object.Module._extensions..node (module.js:598:18)
at Module.load (module.js:488:32)
at tryModuleLoad (module.js:447:12)
at Function.Module._load (module.js:439:3)
at Module.require (module.js:498:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/src/app/node_modules/node-zopfli/lib/zopfli.js:7:14)
at Module._compile (module.js:571:32)
at Module._extensions..js (module.js:580:10)
at Object.require.extensions.(anonymous function) [as .js] (/usr/src/app/node_modules/babel-register/lib/node.js:152:7)
from compression-webpack-plugin.
What version of node/npm is required?
from compression-webpack-plugin.
What version of node/npm is required?
@Eightyplus webpack 1 + plugin should be fine with node>= 0.12.x
&& npm >=2.x
, webpack 2 requires node >= 4
/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.14' not found (required by /usr/src/app/node_modules/node-zopfli/lib/binding/node-v51-linux-x64/zopfli.node)
This is a node native modules (C/C++) issue in node-zopfli
the glibc on your system may mismatch with the one required by node-zopfli
. Why and if this an issue because of the node version in use etc., I'm no real help here, since C/C++ isn't my daily bread :D
from compression-webpack-plugin.
Hi, it turn out it is a build vs. runtime environment issue. Sorry about that.
from compression-webpack-plugin.
@Eightyplus Hey, I've got the same issue.
Error: Cannot find module '/usr/src/app/node_modules/node-zopfli/lib/binding/node-v51-linux-x64/zopfli.node'
at Function.Module._resolveFilename (module.js:470:15)
at Function.Module._load (module.js:418:25)
How did you solve this? Thanks
from compression-webpack-plugin.
Well, the build/runtime environment was different, so the packages has to be rebuild as suggested
rm -rf node_modules && npm install
from compression-webpack-plugin.
Maybe your production env is different from the other env's. I would check my webpack.config.js
then.
from compression-webpack-plugin.
@Eightyplus - For reference, zopfli is being split out into it's own lib in the upcoming Major version of compression-webpack-plugin.
from compression-webpack-plugin.
@d3viant0ne thanks for letting me know!
from compression-webpack-plugin.
FYI the [email protected]
release officially removes the loose dependency. More information can be found in the changelog.md
from compression-webpack-plugin.
Related Issues (20)
- [types] Failed to import new types HOT 3
- [types] `@gfx/zopfli` can't be used with new types HOT 3
- Getting error TS1005: '?' expected HOT 2
- Always 404, I don't know why, HOT 2
- gzipped css not updated in html file HOT 19
- compress images not work HOT 2
- TypeError: Cannot read properties of undefined (reading 'tapPromise') HOT 1
- Allow usage of 6.x version without md4 HOT 4
- ERROR in Conflict: Multiple assets emit different content to the same filename css/.gz HOT 1
- Restoring failed for CompressionWebpackPlugin; HookWebpackError: this._obj.updateHash is not a function HOT 5
- Some of the files ignored during build compression HOT 10
- How to do this compression from express? HOT 1
- How to use deleteOriginalAssets is true ? HOT 2
- Compressed build now working on browser HOT 6
- Version 6 (for Webpack 4) does not work on Node 18+ HOT 10
- Let users exclude files or folder from deleting original assets. HOT 1
- Compression-webpack-plugin running before HtmlCriticalWebpackPlugin completes. HOT 2
- Ability to exclude files from deletion after zipping. HOT 1
- Type definition `BasePluginOptions` property `test` should use `Rules`, not `Rule`
- compression-webpack-plugin .woff compression is not supported HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from compression-webpack-plugin.