gulpjs / gulpjs/gulp

Error resolving symlink after upgrade to Gulp v5

Open
#2,818 2 comments 3 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
32.9k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

Before you open this issue, please complete the following tasks:

* [x] use the search bar at the top of the page to search this repository for similar issues or discussions that have already been opened.
* [ ] if you are looking for help from the gulp team or community, open a [discussion](https://github.com/gulpjs/gulp/discussions).
* [ ] if you think there is a problem with the plugin you're using, open a [discussion](https://github.com/gulpjs/gulp/discussions).
* [x] if you think there is a bug in our code, open this issue.

### What were you expecting to happen?

We have a few symlinked icons in our repo. The symlinked files should have been processed by the pipe, and written to the `dest`.

### What actually happened?

After migrating from Gulp v4.0.2 to v5.0.0, Gulp claims that the files do not exist.

### Please give us a sample of your gulpfile

The full file is available [on GitHub](https://github.com/openfoodfacts/openfoodfacts-server/blob/e33bea5931cab7f321db55349290137b3551ad09/gulpfile.ts). The main task relevant to this issue could be boiled down to this:

```ts
import { dest, src } from "gulp";
import svgmin from "gulp-svgmin";

export function icons() {
return src("*.svg", { cwd: "./icons" }).
pipe(
svgmin({
// @ts-ignore
configFile: "icons/svgo.config.js",
})
).
pipe(dest("./html/images/icons/dist"));
}
```

### Terminal output / screenshots

> #22 2.076 [19:15:24] Starting 'icons'...
> #22 2.102 [19:15:24] 'icons' errored after 26 ms
> #22 2.103 [19:15:24] Error: ENOENT: no such file or directory, lstat 'material/baseline-account_box-24px.svg'
> #22 2.104 [19:15:24] Finished 'default' after 49 ms

([GitHub Actions log](https://github.com/openfoodfacts/openfoodfacts-server/actions/runs/9553413937/job/26332170105?pr=10455#step:4:249))

### Please provide the following information:
* OS & version [e.g. MacOS Catalina 10.15.4]: GitHub Actions (`ubuntu-latest`)
* node version (run `node -v`): v20.15.0
* npm version (run `npm -v`): 10.7.0
* gulp version (run `gulp -v`): CLI version: 3.0.0, Local version: 5.0.0

### Additional information

Gulp v4 performs this task just fine. The icons are definitely available in the repo: https://github.com/openfoodfacts/openfoodfacts-server/tree/e33bea5931cab7f321db55349290137b3551ad09/icons

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.