Bug description
Cannot access the zstd file in windows!!
Answers appreciated!!
Screenshots/recordings
superset@0.0.0-dev dev-server cross-env NODE_ENV=development BABEL_ENV=development node --max_old_space_size=4096 ./node_modules/webpack-dev-server/bin/webpack-dev-server.js --mode=development
INFO: Could not find files for the given pattern(s). [webpack-cli] Failed to load 'C:\Users\trias\superset\superset-latest\superset-frontend\webpack.config.js' config [webpack-cli] Error: Can not access zstd! Is it installed?
Superset version
master / latest-dev
Python version
3.11
Node version
18 or greater
Browser
Chrome
Additional context
No response
Checklist
- [X] I have searched Superset docs and Slack and didn't find a solution to my problem.
- [X] I have searched the GitHub issue tracker and didn't find a similar bug report.
- [X] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.
Comment From: dosubot[bot]
Hey there, @darwindennis03! I'm here to help you with any bugs, questions, or contributions you have for Superset. Let's work together to solve this issue!
I found some similar issues and discussions that might help you resolve the problem:
- Similar Discussions:
- Problems encountered in the secondary development of superset [1]
-
Similar Issues:
- zstd not found by superset_node during docker compose up dev mode (Closed) [3]
- This issue was resolved by a pull request: fix(install/docker): use zstd-baked image for building superset-frontend in containerized env.
To address the specific error you're encountering, ensure that the zstd
dependency is correctly installed and configured. The zstd
dependency is specified and used in the superset-frontend/webpack.proxy-config.js
file:
const { ZSTDDecompress } = require('simple-zstd');
// ...
if (responseEncoding === 'zstd') {
uncompress = ZSTDDecompress();
}
Steps to Install zstd
on Windows:
- Install
simple-zstd
Package: Ensure that thesimple-zstd
package is installed in your project. You can install it using npm:
sh
npm install simple-zstd
-
Verify Installation: After installation, verify that the package is correctly installed by checking your
node_modules
directory forsimple-zstd
. -
Check Configuration: Ensure that your
webpack.proxy-config.js
file correctly imports and uses theZSTDDecompress
function from thesimple-zstd
package.
If you continue to experience issues, please provide additional details about the error messages or any specific configurations you have in place.
To continue talking to Dosu, mention @dosu.
Comment From: darwindennis03
Problem is simple-std package itself uses zstd in background . When i inspect the simple-std node package it has const find = (process.platform === 'win32') ? 'where zstd.exe' : 'which zstd';
which checks for the zstd .
Any suggestions regarding this .
Comment From: dosubot[bot]
The simple-zstd
package relies on the zstd
executable being available on your system. Since you're on Windows, you'll need to ensure that zstd.exe
is installed and accessible in your system's PATH.
Steps to Install zstd
on Windows:
- Download
zstd
Executable: - Go to the Zstandard releases page.
-
Download the appropriate
zstd
executable for Windows (usually found in thezstd-vX.X.X-win64.zip
file). -
Extract and Place
zstd.exe
: - Extract the contents of the downloaded ZIP file.
-
Place
zstd.exe
in a directory that is included in your system's PATH. Common directories includeC:\Windows\System32
or any other directory that is already in your PATH. -
Add Directory to PATH (if needed):
- If you placed
zstd.exe
in a custom directory, you need to add this directory to your system's PATH. -
To do this, follow these steps:
- Open the Start Menu and search for "Environment Variables".
- Select "Edit the system environment variables".
- In the System Properties window, click on the "Environment Variables" button.
- In the Environment Variables window, find the "Path" variable in the "System variables" section and select it.
- Click "Edit" and then "New" to add the directory where
zstd.exe
is located. - Click "OK" to close all windows.
-
Verify Installation:
- Open a new Command Prompt window and run the following command to verify that
zstd
is accessible:sh where zstd.exe
- If the command returns the path to
zstd.exe
, the installation is successful.
After completing these steps, try running your development server again. This should resolve the issue with accessing zstd
on Windows.
To continue talking to Dosu, mention @dosu.
Comment From: darwindennis03
@dosu Can u provide discussion link for superset build tools installation required for windows .
Comment From: webobite
I am facing same issue for Mac OS as well, any solution for the same ?
Comment From: hainenber
@webobite on Mac, you need to install zstd
via Homebrew (brew install zstd
)
Comment From: hainenber
@darwindennis03 might I know if you are running dev-server
in WSL or native Windows? If it's the latter case, and assuming you're using Ubuntu/Debian-flavoured distro, you can install zstd
via apt-get install zstd
.
I'll probably make a PR to add these steps as instructions.
Comment From: darwindennis03
Native windows 32bit . Waiting for that PR thanks .
Comment From: webobite
@webobite on Mac, you need to install
zstd
via Homebrew (brew install zstd
)
Thanks, It worked for me.
Comment From: darwindennis03
when i inspect simple-zstd package it still checks for the path of the zstd installation. Do i need to have it in my windows build tools or something like that .
Comment From: rusackas
Just adding that we don't officially support Windows... but if you add (or anyone adds) some docs/scripts/support to make Superset work on Windows reliably, maybe we can in the future.
Comment From: Ettery
I'm building on a headless Ubuntu installation on WSL.
zstd and simple-zstd installed successfully, but when I npm run build
i get the error:
> superset@0.0.0-dev build
> cross-env NODE_OPTIONS=--max_old_space_size=8192 NODE_ENV=production BABEL_ENV="${BABEL_ENV:=production}" webpack --color --mode production
INFO: Could not find files for the given pattern(s).
[webpack-cli] Failed to load 'C:\dev\github\superset\superset\superset-frontend\webpack.config.js' config
[webpack-cli] Error: Can not access zstd! Is it installed?
Webpack seems to be using Windows syntax to access the webpack.config.js which looks weird.
If I try to run zstd I get:
stdin is a console, aborting
Any suggestions?
Comment From: Craiqser
[webpack-cli] Failed to load 'C:\dev\github\superset\superset\superset-frontend\webpack.config.js' config [webpack-cli] Error: Can not access zstd! Is it installed?
cd superset-frontend npm i simple-zstd
Comment From: rusackas
npm i simple-zstd
This looks like it's already in package.json
- does having this installed fix things for everyone? If so, perhaps we can close this one out 🤞
Comment From: Craiqser
npm i simple-zstd
This looks like it's already in
package.json
- does having this installed fix things for everyone? If so, perhaps we can close this one out 🤞
The text of the error was exactly the same, and it helped me. I can’t say that it went wrong with me when installing packages from the dependencies section.
Comment From: rusackas
Sounds like it's a non-issue now days. Closing, but holler if I've overstepped and this needs revisiting!