sindresorhus / awesome-lint

Linter for Awesome lists
MIT License
600 stars 56 forks source link

Unable to find valid readme #178

Closed jamesponddotco closed 9 months ago

jamesponddotco commented 9 months ago

I'm probably missing something obvious, but for some reason I keep getting this error when running the linter:

[/tmp/awesome-lint][main] ./cli.js https://github.com/jamesponddotco/awesome-privacy-front-ends ✖ Unable to find valid readme for "https://github.com/jamesponddotco/awesome-privacy-front-ends"

If you look at the repository, you'll see that the README.md file is indeed there and the #readme link works. I am not sure what the issue is.

Could someone shine some light into this issue, please? I would like to use the linter to check for further issues in the repository before opening a pull request on sindresorhus/awesome.

bgaillard commented 9 months ago

Hello, I encounter the same problem with https://github.com/bgaillard/readonly.nvim Github repository.

Last version returns that it does not find the readme file even if I have a README.md file.

image

If I use the previous version 0.18.6 it works.

image

I did not write Node.js code since a long time but tried to debug it, the problems seems to be inside the index.js file on the call to the gitClone method (https://github.com/sindresorhus/awesome-lint/blob/main/index.js#L70).

Neovim gives me the following warning when I open the file.

image

If I add a blocking sleep after the call to gitClone it works.

The problem is that the git-clone library provides 2 methods, a sync one and an async one, we have to use the asycn one.

The following PR fixes it I think https://github.com/sindresorhus/awesome-lint/pull/179

bgaillard commented 9 months ago

Thanks @sindresorhus :+1:

jamesponddotco commented 9 months ago

Thanks, @sindresorhus!