3 ms·
“So I spent a week doing OAuth2 stuff. It took a couple days to read through [Google’s] ten-thousand lines of code, so then I went and looked for other librarie
by crdrost 5y ago
“So I spent a week doing OAuth2 stuff. It took a couple days to read through [Google’s] ten-thousand lines of code, so then I went and looked for other libraries. There's `python-oauth2`... it's the second version of python-oauth, it doesn't actually do OAuth2. But that took a while to figure out. So that one was a little bit better, 540 source lines of code, 15 classes, but I wasn’t going to put that in either because it didn’t actually do what I needed to do. So I rewrote that to just do bearer-token authentication, it’s ‘python-foauth,’ or if you prefer, ‘eff oauth.’”
-- Jack Diederich, “Stop Writing Classes”, https://youtube.com/watch?v=o9pEzgHorH0 https://youtube.com/watch?v=o9pEzgHorH0
- neolog 5y agoIn cases where the name is ambiguous you can use another name like python-oauth-v2.
- 0xbadcafebee 5y agoWith CPAN this was solved by hierarchical package/class naming. Net.pm Net/IMAP.pm Net/IMAP/SSL.pm ^ Each of those is published by a different author, and inherits the previous one to add features. As a result CPAN is a tremendously useful library of OO, not because they're all different, but because they are designed to inherit and extend existing code, rather than re-write the whole thing and have 500 differently-named-almost-identical codebases. CPAN's been around for decades, and everybody talks about DRY code, and yet no other language seems to want to actually reuse and extend code.