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

Bug: Errors with symlinks in staging area and markdownlint #1231

Open
brynary opened this issue Nov 27, 2024 · 1 comment
Open

Bug: Errors with symlinks in staging area and markdownlint #1231

brynary opened this issue Nov 27, 2024 · 1 comment

Comments

@brynary
Copy link
Member

brynary commented Nov 27, 2024

What happened?

We have symlinks committed in our repo. We are seeing errors when a full build runs, initially during the staging phase and then markdownlint crashes.

https://qlty.sh/gh/qltysh/projects/cloud/builds/adbf47a7-88f8-41c8-8665-20ecea319f91

What did you expect to happen?

Successful completion of build

Can you reproduce the problem?

Yes, consistently

CLI Version

qlty 0.452.0 (3124098)

Relevant log output

2024-11-27T00:11:31Z ERROR [ThreadId(8)]::qlty_check::executor::staging_area (20.4 MB): Error reading metadata for: "/home/runner/work/cloud/cli/Cargo.toml"
2024-11-27T00:11:31Z ERROR [ThreadId(7)]::qlty_check::executor::staging_area (20.4 MB): Error reading metadata for: "/home/runner/work/cloud/cli/LICENSE.md"
2024-11-27T00:11:31Z ERROR [ThreadId(7)]::qlty_check::executor::staging_area (20.4 MB): Error reading metadata for: "/home/runner/work/cloud/cli/README.md"
2024-11-27T00:11:31Z ERROR [ThreadId(5)]::qlty_check::executor::staging_area (20.4 MB): Error reading metadata for: "/home/runner/work/cloud/cli/SECURITY.md"
2024-11-27T00:11:31Z ERROR [ThreadId(7)]::qlty_check::executor (20.6 MB): Failed to load config file from repository: Failed to copy config file /home/runner/work/cloud/cli/Cargo.toml to /home/runner/tmp/qlty/qkV1sVRl-rw/cli/Cargo.toml
Caused by:
    No such file or directory (os error 2)

...

2024-11-27T00:12:12Z ERROR [ThreadId(78)]::qlty_check::executor::invocation_result (29.8 MB): 59eIc6: markdownlint/lint STDERR: Error: ENOENT: no such file or directory, open 'cli/SECURITY.md'
    at Object.openSync (node:fs:585:3)
    at Object.readFileSync (node:fs:453:35)
    at lintFile (/home/runner/.qlty/cache/tools/markdownlint/0.42.0-440d039728e1/node_modules/markdownlint/lib/markdownlint.js:887:33)
    at lintWorker (/home/runner/.qlty/cache/tools/markdownlint/0.42.0-440d039728e1/node_modules/markdownlint/lib/markdownlint.js:977:7)
    at lintInput (/home/runner/.qlty/cache/tools/markdownlint/0.42.0-440d039728e1/node_modules/markdownlint/lib/markdownlint.js:1018:7)
    at Function.markdownlintSync [as sync] (/home/runner/.qlty/cache/tools/markdownlint/0.42.0-440d039728e1/node_modules/markdownlint/lib/markdownlint.js:1067:3)
    at lintAndPrint (/home/runner/.qlty/cache/tools/markdownlint/0.42.0-440d039728e1/node_modules/markdownlint-cli/markdownlint.js:327:35)
    at Object.<anonymous> (/home/runner/.qlty/cache/tools/markdownlint/0.42.0-440d039728e1/node_modules/markdownlint-cli/markdownlint.js:333:5)
    at Module._compile (node:internal/modules/cjs/loader:1246:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1300:10) {
  errno: -2,
  syscall: 'open',
  code: 'ENOENT',
  path: 'cli/SECURITY.md'
}
@marschattha
Copy link
Member

This related to https://github.com/qltysh/cloud/pull/5018

Basically right now we don't pull the submodule, but the symlinks are there pointing to the files causing this.

But as I said in that PR, it makes more sense to have the symlinked files ignored since they are scanned as part of this repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants