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

Correct or incorrect handling of NPM capitalization #79

Open
matt-phylum opened this issue Nov 13, 2024 · 2 comments
Open

Correct or incorrect handling of NPM capitalization #79

matt-phylum opened this issue Nov 13, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@matt-phylum
Copy link

matt-phylum commented Nov 13, 2024

NPM package names are case sensitive, but the PURL spec says they must be lowercased (package-url/purl-spec#136). This library is adhering to the PURL spec instead of NPM for NPM types, and mangling some rare NPM package names in an unrecoverable way.

Go module paths are case sensitive, but the PURL spec says they must be lowercased, and this library is adhering to the Go rules (mostly) instead of the PURL spec. Should NPM also deviate from the PURL spec?

@jdalton
Copy link
Collaborator

jdalton commented Nov 14, 2024

@matt-phylum

Thanks for raising this!
Yep, older names were a bit yolo.
We can leverage npm's validate-npm-package-name package to validate this.

@jdalton
Copy link
Collaborator

jdalton commented Nov 15, 2024

@matt-phylum PR up for feedback at #80.

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

2 participants