plotly / dash

Data Apps & Dashboards for Python. No JavaScript Required.
https://plotly.com/dash
MIT License
21.47k stars 2.07k forks source link

run 'npm run build' failed #2117

Open SeekPoint opened 2 years ago

SeekPoint commented 2 years ago

I followed the steps in https://github.com/plotly/dash/blob/dev/CONTRIBUTING.md

(dev) PS D:\ghprj\dash> npm run build

build run-s private::build.*

private::build.components python dash/development/update_components.py 'all'

npx lerna exec --concurrency 3 --scope @('all') -- npm i 🛑 lerna notice cli v4.0.0 lerna info versioning independent lerna notice filter including "@('all')" lerna info filter [ "@('all')" ] lerna ERR! EFILTER No packages remain after filtering [ "@('all')" ]

🚨 Failed installing npm dependencies for component packages: 'all' (status=1) 🚨 ERROR: "private::build.components" exited with 1. (dev) PS D:\ghprj\dash>

since I run python3.6.1, so I use: +black==19.10b0 +pylint==2.12.0

alexcjohnson commented 2 years ago

Oh interesting thanks for the report @loveJasmine! The single quotes are making it through into the string we see in Python when this is run in your shell (so we're getting 'all' instead of all), but in my shell they're stripped and the command runs correctly.

It doesn't look like we actually need the quotes, at least not for the all case, so I can remove them for the next release. If you want to try it now, open package.json and remove those quotes around all on these two lines (or at least the second one, that's the command you're actually running):

https://github.com/plotly/dash/blob/565de531e77e99b339bab7e0838ac51a4a02511a/package.json#L9-L10

SeekPoint commented 2 years ago

(dev_py380) PS D:\ghprj\dash> git diff diff --git a/package.json b/package.json index 097f6a53..3730839f 100644 --- a/package.json +++ b/package.json @@ -6,8 +6,8 @@ "private::format.renderer": "cd dash/dash-renderer && npm run format", "private::format.dcc": "cd components/dash-core-components && npm run format", "private::initialize.renderer": "cd dash/dash-renderer && npm ci",

(dev_py380) PS D:\ghprj\dash> npm run build

build run-s private::build.*

private::build.components python dash/development/update_components.py all

npx lerna exec --concurrency 3 --scope @(dash-core-components|dash-html-components|dash-table) -- npm i 🛑 'dash-html-components' is not recognized as an internal or external command, operable program or batch file.

🚨 Failed installing npm dependencies for component packages: dash-core-components|dash-html-components|dash-table (status=255) 🚨 ERROR: "private::build.components" exited with 1. (dev_py380) PS D:\ghprj\dash>

SeekPoint commented 2 years ago

any update?

T4rk1n commented 1 year ago

Look like some issue with powershell and the way it passes the arguments to the command. Closing #2166 and #2197 as duplicate, this one has more info.

aGitForEveryone commented 1 year ago

Any update on how to make it working on Windows? Both PowerShell and Command Prompt do not work. It's either the issue: lerna ERR! EFILTER No packages remain after filtering [ "@('all')" ] or after removing the quotes as suggested by Alex, it's 'dash-html-components' is not recognized as an internal or external command,.

I have no clue on how to continue