Live data from Hacker News

Ask HN: What open source project, in your opinion, has the highest code quality?

news.ycombinator.com

71–80 of 294 posts

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#72
post #66

I was going to say the GNU version of /bin/false and /bin/true, but I actually took a look at the source and it is terrible.

The original /bin/true is probably the highest quality code ever written, but unfortunately I don’t think the license is OSI approved: http://trillian.mit.edu/~jc/%3B-)/ATT_Copyright_true.html

Gosh, it seems like copyright lawyers will stop at nothing.

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#73
I'm surprised no one has mentioned the Linux Kernel!

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/lin...

It is quite clean when you consider the task that it accomplishes.

Being able to compile across multiple architectures/endian-ness,32/64-bit/scale up/down from server/desktop/router/phone while accepting contributions from thousands of people..

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#74
radare2 - https://github.com/radare/radare2/ More GNU than actual GNU sources, more UNIX than the linux kernel. Huge codebase but extremely easy to get involved with, orthogonal design with no compromise on speed. Best codebase I ever encountered

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#75
post #40

SQLite. and for this reason alone! https://www.sqlite.org/testing.html As of version 3.23.0 (2018-04-02), the SQLite library consists of approximately 128.9 KSLOC of C code. (KSLOC means thousands of "Source Lines Of Code" or, in other words, lines of code excluding blank lines and comments.) By comparison, the project has 711 times as much test code and test scripts - 91772.0 KSLOC.

And this:

https://www.sqlite.org/malloc.html

"SQLite can be configured so that, subject to certain usage constraints detailed below, it is guaranteed to never fail a memory allocation or fragment the heap."

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#76
post #27

Strictly talking about code quality, I will nominate RCP100, which is a small, virtually unknown, now-abandoned routing software written in C [0]. I started programming with C way back in the 90s, and this is one of only two projects I can recall being immediately struck by the beauty of the code (Redis being the other). I know almost nothing about the author but he seems not to want to be known by name. You can brow…

Maybe you just send the guys an email ;)

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#77
post #38

I hold the source code of Go standard library & base distribution (i.e. compiler, etc.) in very high regard. Especially the standard library is, in my opinion, stunningly easy to read, explore and understand, while at the same time being well thought through, easy to use (great and astonishingly well documented APIs), of very good performance, and with huge amounts of (also well readable!) tests. The compiler (includ…

As far as I know, parts of the compiler are still code automatically translated from C, so this may be part of the reason.

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#78

It's funny to see nobody is even questioning the question. What does it even hold as a value to be the project of the highest code quality in the world ? How can it exist as a consensus if we can't even agree on best practices ? If it's for learning purposes, why even look for the ONE project with the HIGHEST quality ? Just go by any GOOD ENOUGH project. I see this all the time: what's the best editor, the best color…

Sometimes you need a recipe book, other times you want to lose yourself in a masterpiece.

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#79
post #54
post #40

SQLite. and for this reason alone! https://www.sqlite.org/testing.html As of version 3.23.0 (2018-04-02), the SQLite library consists of approximately 128.9 KSLOC of C code. (KSLOC means thousands of "Source Lines Of Code" or, in other words, lines of code excluding blank lines and comments.) By comparison, the project has 711 times as much test code and test scripts - 91772.0 KSLOC.

Inversely, this is counteracted by the logic to not use Git: https://sqlite.org/whynotgit.html

how would using a specific vcs improve the code quality?

Re: Ask HN: What open source project, in your opinion, has the highest code quality?

#80
post #79
post #54

Earlier quoted context omitted.

Inversely, this is counteracted by the logic to not use Git: https://sqlite.org/whynotgit.html

how would using a specific vcs improve the code quality?

This was a response to test coverage used as a benchmark. I see them both as an indirect project quality benchmark. Neither is directly representing the actual code quality but does indicate if it is a project that matches my view of a mature project. Sure, others will disagree - but the whole idea of quality in this context is subjective anyway.
Post reply on HN