5 ms·
The argument I saw was that a global namespace ensured: A) Packages can change owners without changing names (and breaking downstreamers) B) It encourages cre
by jopsen 7y ago
The argument I saw was that a global namespace ensured:
A) Packages can change owners without changing names (and breaking downstreamers)
B) It encourages creative names, rather can calling something myusername/http, you have to give the package a real name like hyper, express, curl, etc.
- staticassertion 7y ago> B) It encourages creative names Who wants this?
- steveklabnik 7y agoEmpirically, libraries with unique names are more popular than ones that aren’t. It helps to have a unique name when searching, they’re more memorable, it’s easier to disambiguate between two libraries that do similar things, etc.
- staticassertion 7y ago> Empirically, libraries with unique names are more popular than ones that aren’t. Seems like this is survivorship bias. All of the common names get squatted by people who never push code, and then anyone who's actually going to build something will need to pick something unique. Reqwest is more popular than request, for example. It's not exactly what most would expect, and if you search "request" you get the much less popular crate.
- steveklabnik 7y agoThis is true even in ecosystems that have namespacing. And in hybrid systems, like npm’s, the non-namespaces versions are almost universally more popular than the namespaced ones.
- staticassertion 7y agoInteresting, but I wonder how this works in purely namespaced systems - if non standard names are more popular in, say, maven. I don't know. I'm unconvinced that this is a meaningful metric, and I worry more about typosquatting/ malicious dependencies, which, to my knowledge, crates.io does almost nothing to proactively deal with.
- steveklabnik 7y agoNamespacing doesn’t solve typosquatting or malicious dependencies. You typosquat the namespace instead. Any dependency can become malicious.
- staticassertion 7y agoYeah, you're right.
- Can_Not 7y agoBut A) you could still implement giving ownership to another user without giving the other user your whole namespace and B) why would you even want B?
- jopsen 7y agoIf you give ownership without changing the organization that owns the package it then signals trust.. Usually, orgs won't be comfortable with this.. (B) is brilliant... We all know what EC2 and S3 is... If Amazon had just called these services for: compute and storage, there wouldn't be any brand. Branding makes things easier to search for and to talk about. All this said, these downsides might be worth it
- Can_Not 7y agonpm install @aws/s3 works for me. npm install burrito doesn't.