Live data from Hacker News

Ask HN: What are some well written/engineered open source software?

news.ycombinator.com

21–30 of 72 posts

Re: Ask HN: What are some well written/engineered open source software?

#26
I've learned quite a bit from reading through the Laravel source - https://github.com/illuminate

edit for details: The authors are quite meticulous (notoriously, every comment in a multi-line comment is 3 characters less than the previous) and stick to the "convention over configuration" mantra no doubt inspired by Ruby on Rails. It's interesting to see how they create abstractions to simplify so many common web dev tasks.

Re: Ask HN: What are some well written/engineered open source software?

#27
I've spent a lot of time reading C sources. Standouts are nginx, mbed TLS, Amazon s2n. Clean coding styles, consistent in checking function return values (very important! significant source of vulnerabilities in C software), comments where due, no hacks.

Among the most convoluted source codes I've read is Tor. It works (apparently), and it isn't even very insecure per se (the code is littered with hard asserts that will abort code execution if an expected condition isn't met), but it is unnecessarily dense. Example: I use software to analyze the call graph (which function calls which function) and when I ask it to find potentially recursive loops (A() calls B() calls A() etc) it spews out tens of thousands of potential recursions.

By comparison, mbed TLS only has a couple of these, and a large project like OpenSSL 50 or so.

Conversely, C software that isn't consistent in error signaling (return -1 on error in function A, return 0 in function B, set parameter int* err in function C, etc), doesn't perform due error checking, whose call graph is spaghetti, mindlessly performs multiplication (leading to overflows with certain inputs), uses signed or unsigned int where size_t is better suited, are usually susceptible to bugs and abuse (vulnerabilities). The projects I mentioned are very clean in this regard.

Re: Ask HN: What are some well written/engineered open source software?

#28
post #24

Many names put out there, but not much substantiation. If you are going to drop a name, could you explain why it is well written/engineered?

One could argue the question is way too vague. What is a "well written/engineered" software to begin with?

Re: Ask HN: What are some well written/engineered open source software?

#29

Asterisk PBX. Well-chosen small set of module types (channel drivers, applications, functions, resources, codecs & formats), allowing to implement literally any behaviour, and converge with any thinkable external technology. Not working in VoIP anymore for quite long time, but the clarity of design of Asterisk has deeply influenced me. Gstreamer. Pipeline is very powerful model for software, the potential of it is tr…

I am grateful to work with a few of the asterisk developers and they strive hard for quality. A project that long running and feature-rich is not easy to keep up to date, stable and well architected. If you want to see a project with professional commit messages, it is a solid example (the past several years at least).

https://github.com/asterisk/asterisk/commits/master

Post reply on HN