|
|
|
Ask HN: Understanding a large python codebase
|
|
12 points
by bonobo3000
3809 days ago
|
|
I have recently started working at a company with a massive python codebase. I'm finding it really hard to understand what is going on because of the lack of types. I don't know what the arguments to functions are supposed to be or what they are returning, and because its a fairly sophisticated, large microservice architecture it is even harder to trace things across services. My experience before this was working on a much smaller Java codebase - it was written well and really easy to understand. The fact that we didn't really have much tooling was a huge help to me too - so when I deployed a service for example, I could see the shell commands and its basically a "mvn package; scp ...; start ...". When i wanted to know where the logs go, I look at a log4j config in the project. When i want to know whats running, I ssh in and "ps aux | grep x" - there are maybe 10 servers tops for a project. This is a much bigger company with hundreds of services, lots of machines, complex deploy procedures and in general just much more abstraction both in codebase and ops. My normal approach is to just dig deeper and peel back the abstractions until I see whats happening. I fear thats impossible here. Instead, we ask someone who built it or look at an outdated wiki, which is great but just so much more painful than actually knowing how everything fits together. I am kind of lost as to where to even start understanding this codebase. The 3 main challenges being 1. no type information, 2. massive codebase, 3. ops complexity. What are your tips for getting to grips with this whole system? Any advice is welcome. |
|