Closed howiezhao closed 2 years ago
@howiezhao Yes, copy-props@>=2.0.5
uses is-plain-object@^5.0.0
. (copy-props@<=2.0.4
uses is-plain-object@^2.0.1
)
@howiezhao I tried your gulpfile.js
, and gulp
is work normally.
If you use package-lock.json
, please npm install
again after removing it.
devDependencies
of package.json
is as follows:
{
...
"devDependencies": {↲
"autoprefixer": "^10.4.8",↲
"browser-sync": "^2.27.10",↲
"cssnano": "^5.1.12",↲
"google-closure-compiler": "^20220719.0.0",↲
"gulp": "^4.0.2",↲
"gulp-concat": "^2.6.1",↲
"gulp-debug": "^4.0.0",↲
"gulp-google-closure-deps": "0.0.5",↲
"gulp-imagemin": "^7.1.0",↲
"gulp-plumber": "^1.2.1",↲
"gulp-postcss": "^9.0.1",↲
"gulp-rename": "^2.0.0",↲
"gulp-sass": "^5.1.0",↲
"gulp-sourcemaps": "^3.0.0",↲
"gulp-uglify-es": "^3.0.0",↲
"pixrem": "^5.0.0",↲
"postcss": "^8.4.14"↲
}↲
}
And the result is as follows: (gulp-sass
causes an error)
$ node -v
v10.23.0
$ npm -v
6.14.8
$ npx gulp generate-assets
[22:25:33] Using gulpfile ~/home/play/daily/20220801/gulpjs/trial/gulpfile.js
[22:25:33] Starting 'generate-assets'...
[22:25:33] Starting 'styles'...
[22:25:33] Starting 'vendorScripts'...
Error in plugin "gulp-sass"
Message:
gulp-sass no longer has a default Sass compiler; please set one yourself.
...
Going to close this as, like @sttk stated, it's a dependency lockfile issue.
Before you open this issue, please complete the following tasks:
What were you expecting to happen?
When I use the
gulp
command I expect it to work.What actually happened?
When I use the
gulp
command, the program reports an error and exits abnormally.Please give us a sample of your gulpfile
Terminal output / screenshots
Please provide the following information:
node:10-stretch-slim
docker imagenode -v
):node:10-stretch-slim
docker imagenpm -v
):node:10-stretch-slim
docker imagegulp -v
): 4.0.2Additional information
It looks like
gulp
depends ongulp-cli
, andgulp-cli
depends oncopy-props
, when I downgradedcopy-props
to 2.0.4 everything works as usual, is it related to the 2.0.5 updateis-plain-object
version?