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

Skypack shows German language README for Alpinejs #68

Closed
earthboundkid opened this issue Nov 7, 2020 · 2 comments
Closed

Skypack shows German language README for Alpinejs #68

earthboundkid opened this issue Nov 7, 2020 · 2 comments
Labels
bug Something isn't working

Comments

@earthboundkid
Copy link

See https://www.skypack.dev/view/alpinejs.

It should show https://github.com/alpinejs/alpine/blob/master/README.md but instead shows https://github.com/alpinejs/alpine/blob/master/README.de.md.

Also made an issue on Alpine in case the error is on their end: alpinejs/alpine#867

@FredKSchott
Copy link
Collaborator

FredKSchott commented Nov 17, 2020

Thanks for the ping! @drwpow any idea why this could be happening? It looks like we're just trying to fetch README.md from the repo, which appears to be english.

@drwpow
Copy link

drwpow commented Nov 17, 2020

This is fascinating! To be honest, I’m baffled. The reason we show a German README is because that‘s what npm told us the readme was:

http://registry.npmjs.com/alpinejs

Screen Shot 2020-11-17 at 10 48 20

According to npm’s registry they even specify "readmeFilename": "README.de.md" almost to double down on this. So for this package in particular, npm was really keen on making sure we showed German 😅 .

My best guess as to “why German” is: if you look at that package’s repo, of all the files that start with README*, README.de.md is the first, alphabetically. My guess is that they do a scan for any file starting with README and take the first, even if README.md exists.

However, if you go to npm’s package page for AlpineJS, they show the English version:

Screen Shot 2020-11-17 at 10 50 41

I don‘t really know how to explain the difference between what npm is giving us and what they‘re displaying on their end.

A little more detail that may explain the issue: with Skypack we want to be as-close-as-instant to npm as possible. This means that if we took the extra time to fetch a remote README for every package, we would start slowing down and it could take quite a while between when packages are published to npm and when they show up on Skypack.

However, we’ve had some other issues with npm’s data, so I think we need to have something running in the background that re-populates all the READMEs, without slowing down our update times. But all that said, this is the first time I’ve seen this behavior. So thanks for raising it! 🙂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants