4 ms·
This is one of those ideas that sounds very tempting at the small to medium scale but will definitely fall over at the large scale. Zooko's Triangle is one obvi
by pjc50 7y ago
This is one of those ideas that sounds very tempting at the small to medium scale but will definitely fall over at the large scale. Zooko's Triangle is one obvious problem as the namespace gets full.
It also looks like this is only suitable for functional languages, and possibly just non-OO languages?
What about the type signatures of these functions? What do they look like? How well can different types be substituted? Do we have to version the types as well?
How do we handle testing in this scenario? Every version of every function? How about combinations of functions?
How about deprecation? This is hard enough to do with standard library functions; how long has gets() been deprecated, for example?
- jstimpfle 7y agoConsider that if you control a large codebase, the need for "decentralisation" (as in Zooko's triangle) is not there. You can just rename things. When integrating across maintenance boundaries, renaming isn't possible but a simple prefix is almost as good as a namespace.
- pjc50 7y agoAt the point where the article talks about ""the open source Key-Value database of all functions"", you can't rename things.
- jstimpfle 7y agoYou are right, I'm off on a tangent here.
- coding123 7y agoWhat if the key is module.fn
- pharke 7y agoThe name shouldn't matter. What I mean is, we should only care about the output produced by a given input. The keys could simply be unique hashes but we also associate a full description of the interface, tests, and text describing how it should be used. We would just need tooling that makes it easy to search, run the tests with our data, and locally alias the function to something we understand.