Skip to content
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

NodeJS 22 breaks vinyl-js #350

Closed
maximilianschmid opened this issue Apr 25, 2024 · 2 comments
Closed

NodeJS 22 breaks vinyl-js #350

maximilianschmid opened this issue Apr 25, 2024 · 2 comments

Comments

@maximilianschmid
Copy link

maximilianschmid commented Apr 25, 2024

What were you expecting to happen?

The task should copy the files

What actually happened?

The task throws an error and does not copy files

var gulp = require(‘gulp');

gulp.task('copyMailTemplates', () => {
  return gulp.src(['./src/templates/source/**/*.handlebars.html'])
    .pipe(gulp.dest('_temp/server/templates/source/'))
})

Terminal output / screenshots

>  npx gulp copyMailTemplates

[12:46:09] Using gulpfile ~/extendedbrain/planfred/server/gulpfile.js
[12:46:09] Starting 'copyMailTemplates'...
[12:46:09] 'copyMailTemplates' errored after 13 ms
[12:46:09] TypeError: Cannot assign to read only property 'atime' of object '#<Stats>'
    at onFutimes (/Users/milian/extendedbrain/planfred/server/node_modules/vinyl-fs/lib/file-operations.js:278:27)
    at FSReqCallback.oncomplete (node:fs:188:23)
    at FSReqCallback.callbackTrampoline (node:internal/async_hooks:130:17)

Please provide the following information:

  • MacOS Sonoma 14.4.1]:
  • node version 22.0.0:
  • npm version 10.5.2
  • gulp version
    CLI version: 3.0.0
    Local version: 5.0.0

Additional information

The problem started to occur in NodeJS 22.0.0. The last 21.x dev was working.

I think this problem relates to this change in NodeJS 22

[6f504b71ac] - buffer: use simdutf for atob implementation (Yagiz Nizipli) #52381

How to patch this issue?

Patch file
/vinyl-fs/lib/file-operations.js

uncomment lines 278, 779 and 284,285

CleanShot 2024-04-25 at 12 52 07

@nicolo-ribaudo
Copy link

This is a bug in Node.js - nodejs/node#52707

oddhack added a commit to KhronosGroup/Vulkan-Site that referenced this issue Apr 30, 2024
Attempt to work around nodejs/node#52708 /
gulpjs/vinyl-fs#350 by reverting to previous
LTS version.
oddhack added a commit to KhronosGroup/Vulkan-Site that referenced this issue Apr 30, 2024
Attempt to work around nodejs/node#52708 /
gulpjs/vinyl-fs#350 by reverting to previous
LTS version.
@phated
Copy link
Member

phated commented Jun 25, 2024

Huge shout-out to @nicolo-ribaudo for fixing this in upstream node! I'm going to close this out.

@phated phated closed this as completed Jun 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants