Hacker News new | ask | show | jobs
by m_a_g 1264 days ago
I want to ask the same question for Python and Go. I'd love to see some quality OSS using Python or Go and contribute to them if I can.
8 comments

The best opensource projects that you'll stay interested in the medium-long term are projects you actively use. Anything else you'll get bored of.
The same is true of a encyclopedia. If you try to read it directly, word after word, it is boring. However, if you treat it as a reference, as the OP is asking for in Go code, it can be helpful and possibly inspiring.
Library code is usually quite different from app code.
A lot of the Python standard library is written in Python and a good way to see idiomatic Python code. https://github.com/python/cpython/tree/main/Lib
Honestly, I don't find that very helpful. These, same as all that Hashicorp stuff, are pretty big and quite domain-specific projects, that are somewhat difficult to conceptualize about what they even do. As if the only thing go is being used for are all that distributed virtualization stuff.

Maybe at some point it is nice to look at them, but they don't look very approachable to me, if I just want to take a look at how code is normally written in go beyond some AoC-exercises. Like useful common patterns and such.

For Go, anything from Hashicorp https://github.com/hashicorp
I really enjoy reading Python code from https://github.com/encode/starlette and https://github.com/encode/httpx
My reaction to that question regardless of language is that I expect to find some unreadable code soup.

Which probabaly has 100% test coverage but is abstracted to death.

Probaly the best codebase is something which does not pass scrutiny on every single line, but it "just works".

Id say the go standard library, including /x/ extended stdlib
There is a good thread on this for Python from the last couple of years. Try searching 'python read' or 'python codebase'

The top comment IIRC is about @tiangolo, the FastAPI guy