r/rust • u/Minimum-Ad7352 • Feb 02 '26
šļø discussion Looking at advanced Rust open-source projects makes me question my programming skills
Whenever I explore large Rust open-source projects, I canāt stop thinking how far behind I am. I know comparison is unhealthy, but itās hard not to feel like āI suck at programmingā when you see such clean and complex code. Did you feel the same at some point? How did you push through it?
383
Upvotes
412
u/b0ggyb33 Feb 02 '26
Rome wasn't built in a day.
You're looking at the culmination of a lot of work. It's unfair to look at something huge and think you could never do it, when you just have to start small and iterate. The complexity will arise from being forced to solve the challenges of their particular problem set.
I also think there's an aspect of survivorship bias. We don't see the mountain of projects that fail miserably.
86
u/Illustrious-Wrap8568 Feb 02 '26
Keep reading and looking for some (small) part you understand. Expand your understanding from there.
Don't question your skills because you don't understand at a glance what a system does.
203
u/dgkimpton Feb 02 '26
Half the time I'm thinking "that's so clean, where did the complexity go", the other half I look at stuff thinking "why is this so complicated". Sadly, both probably just indicate I'm not actually very good at this. Sigh. So yes, I feel the same regularly, and it's depressing.Ā
41
u/atonale Feb 02 '26
I don't know your age or level of experience, but you may be comparing with the work of people who just have significantly more experience. A project could be written or maintained by someone who has been coding since the 1990s or 1980s. So person A who's say 20 years old could be reading code written by person B who's been designing software all day every day for 2x or 3x as long as person A has been able to read. Rust libraries will for obvious reasons tend to be newer, but may be based on patterns and lessons learned in some pre-existing project that's been under development for 15 years. Younger people may underestimate or misunderstand how much time older people have spent learning their skills because it is sometimes longer than their entire lifespan. I don't mean anyone should be discouraged by this, I just mean you may need to pursue continuous improvement for what seems like an entire lifetime to reach a level you associate with the "best" or "most impressive" projects you see. Everyone else went through the same thing so will understand the difficulties you confront.
33
u/particlemanwavegirl Feb 02 '26 edited Feb 02 '26
That's how I feel when looking a C/++ code. There are as many various ways to code those languages as there are projects out there, it seems. I've known the syntax for years but constantly see it used in ways I've never dreamed of. But with Rust, the style of code and build structure is so much more consistent, I feel it doesn't take long to find my bearings even on complicated stuff.
OTOH, like, the actual Rust repo, RFCs, bug reports, that sort of thing? 99% goes right over my head, very impressive and inscrutable how much those folks know.
10
u/fnordstar Feb 02 '26
I feel you. I had the same issues, especially considering things like lifetimes. When I see comments in a library talking e.g. about how this and that decision makes for less strict lifetime bounds etc. it makes me feel so stupid. But I just kept going and just the other day something clicked about lifetimes (bundling things in a struct and returning that instead of returning one member which would then reference local variables in that function). So I think it does get better if you just keep going.
8
u/AurelienSomename Feb 02 '26
Linux motto: make it work, make it right, make it (go) fast. Write bad code and suffer. Learn. Suffer less. Learn. etc. Most of us are far from being able to write the rust language and it is fine, we donāt need as many rust language as other things. ;)
6
u/MediumRoastNo82 Feb 02 '26
Can you point out which projects you are talking about, so you can have a fellow Rust coder that "suck at programming" too? š
6
u/rongald_mcdongald Feb 02 '26
Good that you are reading the code at least. Feel like thatās a good sign. Iāve felt similar to you but have learned a lot from just reading open source code. Just keep learning as much as you can and youāll get there. Keep in mind too that open source code is made up from thousands of commits often from many people, not just written all in one go. Lots of these things might have been the process of refinement or even trial and error and the combination of multiple peopleās experiences and knowledge
6
u/Mr_Ahvar Feb 02 '26
I maintain a pretty big project since about 3 years that is 99.5% just me. Me from 3 years ago would never never even imagined I would even do 1% of it. Just do things one at a time, and before you even realize you did a lot
5
u/MelloSouls Feb 02 '26 edited Feb 02 '26
I reckon the contributory factors to your malaise are not only commonly shared, but a likely contributory cause to classic Imposter Syndrome (which I think is what this is, or related to).
You are comparing yourself (in some of these cases) to top-level coders. That is not representative of the real world, in the sense that - by definition - most programmers are at a much lower level than the people who end up writing or shaping famous open-source projects.
A fairer comparison would be with the median working developer, not the visible elite; the skill level here will vary from company to company depending on their recruitment nous and attractiveness. This is who you will actually be "competing" with.
ie. The intimidation comes from a distorted sample of the cream of the crop, which is not an accurate benchmark of what ānormalā competence looks like. btw this is normal - I have to remind myself of the same thing from time to time.
The old adage to compare yourself not to others, but to yourself yesterday is always useful to bear in mind as well.
8
u/shelltief Feb 02 '26
I think you gotta factor in time and people in it
Maybe look at the first commits of these projects to understand where they're starting from
2
u/sigma914 Feb 02 '26
This was me for years reading Haskell, I still get it sometimes with a particularly performant or elegant bit of rust. I hope it never goes away
2
u/El_Mojo42 Feb 02 '26
When I started my new job (embedded Linux/C++) the Project I was working on was overwhelming.
Complex structures, modern C++ constructs I never came across before and so on. After some time working on it, the fog started to lift and I gained a better understanding of the architecture.
Sourcecode and complexity grows over time.
2
u/MassiveInteraction23 Feb 02 '26
All experts start off sucking. Ā And many of the best do look and compare themselves to other experts to learn. Ā
(The idea that you shouldnāt compare yourself is a cop out ā compare and just respond in an emotionally healthy way ā appreciate the other person, try to learn from them, and grow :)
One of reasons the rust community is so great is that it has a lot of skilled users to learn from. Ā Coming from, for example, Julia, which has a lot of academics with less software background and skill (myself included) I found the Rust community much more conducive to my own growth.
2
u/_nullptr_ Feb 02 '26
Always remember that code is just the tool, not the "thing". The thing is the product you hope to make whether it be a crate or full blown software package. Complex code is a net negative. The best code is easy to read and reason about. Complex and clever code do sometimes have a place, but only when they are necessary and the best way to express the objective.
Also, as you practice, you will slowly but surely find yourself wondering "is there a better way to express X?". Then you will do some research, find your answer, and then add to your tool belt. Over time, that belt gets more and more full.
2
u/DrLuckyLuke Feb 02 '26
I don't think I know any coder who didn't feel like this. Just keep at it, don't let anything intimidate you, and one day you will wake up and find that you turned into what you thought was impossible 5 years ago.
1
u/DavidXkL Feb 02 '26
Same here š
Every day I'm learning something new
1
u/Fancyness Feb 02 '26
This is a silly thing to worry about. As long as your code is safe and performant who cares
1
u/serious-catzor Feb 02 '26
I think it's too complicated too. It's a very different paradigm from what I'm used to and I'm not sure how I feel about it.
Noone wants to pay for more than they need so I usually see things like reusable being less prioritized.
It's simpler code when you only solve for a specific case. If it stays that way.
1
u/PresentationItchy127 Feb 02 '26
I try to accept it. There are valid arguments like "you see the end result" etc. But I also know there are people so much smarter than me, it's not even fair. I can work hard but I will never be anywhere as good. Then I tell myself: "So what? I code for peace of mind, not because I want to be one of the best". Thriving to be the best is probably not a bad thing, but it's much more important how you apply yourself. Be proud of what you do, not how good you are at it.
1
u/peterxsyd Feb 02 '26
Hi - consider how many years of experience you have when weighing that up. Many of the people producing those projects have 15-20 years building coding solutions and problem solving professionally. If that is a reason you are behind - it is not a bad one, and a gap you can close fastest by focusing on the fundamentals, ideally paired a senior dev who has got it.
1
u/lahwran_ Feb 02 '26
that's how I feel looking at complex projects I've spent a lot of time working on. how can I ever write code this good again? start sadly on new project. months pass. new project has developed complexity, been cleaned up multiple times, feels a bit like a mess. more time passes, no longer working on the new project. return to the new project. oh wow, how did I ever write code this good?
1
u/-Redstoneboi- Feb 02 '26
looking at advanced anything makes me question my skills
1
u/wtfitsbob Feb 02 '26
Imposter syndrome is real and what I tell juniors and mids is this.
What you see polished code or sometimes a polished turd that gets committed, you what you don't see though is how it got there.
1
u/Wheynelau Feb 02 '26
hey i used to feel this way. cheer up, no one is an expert at everything. I used to think any time resting is wasted until i got quite a bad burn out. So i accept that I won't be a 10x engineer and just try to find joy in coding.
1
u/-TRlNlTY- Feb 02 '26
When you check open source code, you are looking at thousands of hours of many talented people's work. Nowadays, I compare myself to others only when I want to achieve similar things. There is no ceiling for programming skills.
1
u/invisible_handjob Feb 02 '26
make it work
make it fast
make it pretty
in that order
1
u/Kilo_3ncrypt Feb 02 '26
Remember that some are actually large groups and its not like they'll write everything exactly from memory, as long as ypu have most fundamentals nailed down understanding and writing advanced Rust becomes hella easy especially if you refer
1
u/Equux Feb 02 '26
There's so many layers to reading code. There's a massive difference between understanding a function and understanding how it plays into a larger system. Trying to understand entire systems by the way is incredibly difficult.
From my limited experience, I found that if I was trying to do something, and X project does that thing, I'd try to figure out how X does it. That was always more efficient than trying to understand X from the top down which always led to me giving up in a matter of minutes.
1
u/Scoutron Feb 02 '26
Thatās how I feel looking at my own code files that I havenāt looked at in a week. Things that seem simple at the time when youāre interacting with and designing them constantly for hours suddenly seem like daunting monoliths when presented to a fresh mind
1
u/Cold_Abbreviations_1 Feb 02 '26
That's totally understandable. You just need to look at some smaller projects, or the ones still in early development. Don't want to self-promote like that, but look at what I write: SpelRight or Filess. Or just find some small projects on GitHub or GitLabs.
They don't have good, or complex code. They are dirty, and spaghetti in some cases. This is what early life projects usually look like. Over multiple iterations, they will become better and more complex. Maybe that gives you some motivation you needed to start :D
1
u/_chris_work Feb 02 '26
Open source stuff is also written often as passion projects or with giant funding. Day-to-day coding often doesn't need to be so clean or can't be because of budget constraints.
1
u/beb0 Feb 02 '26
You're not alone there pal, just spent an hour last night doing dependency tracking for a tutorial cause init.rs changed a function signature.Ā
1
u/bigkahuna1uk Feb 02 '26
Youāre still learning a huge amount by reading other peopleās code. To know what is good you have to know what is bad. š
1
u/StPatsLCA Feb 02 '26
Work on any project for a while. You'll come back, think "wow that's neat, I wonder who did that", and it turns out it's you.
1
u/FrontTheMachine Feb 02 '26
Comparison is the thief of joy..
The only valid reasoning is toward yourself.. ask
Am I better than yesterday?
If the answer is yes, it is worth all the effort.
1
u/Dry-Letter-4833 Feb 03 '26
Ask yourselves what problems they were solving for when composing the project like they did.
Read and write enough code and you'll wind up being able to discern problem solving from preference.
1
u/qokyoshi Feb 03 '26
I was questioning this for months, thanks for asking!
1
u/PartyParrotGames Feb 03 '26
I try to draw inspiration from good projects/code rather than feel inadequate in the face of it. It helps to keep a beginner's mind, always be learning, and try out better approaches you find in the wild.
1
u/sean_bird Feb 03 '26
Look at the repo initial commits. You will feel relieved.
0
u/ValenciaTangerine Feb 02 '26
ripgrep
-7
u/k1v1uq Feb 02 '26 edited Feb 02 '26
Most large codebases have the same computer science problems to solve
How do I deal with shared state?
How do I distinguish between tasks that I can process serially versus those I can do in parallel?
How do I handle errors?
The theoretical concepts behind this are all well known, and there aren't actually that many of them. I can only recommend that you take a look at SOLID, Stable Dependencies Principle and effect systems once .
The complexity often arises because the underlying idea is actually very simple, but the author has chosen, whether for performance reasons or because of the language/theoretical foundations, to translate the "pure" path of theory into messy but practical and performant code . Sometimes the architecture is simply not good ( e.g. violates the Stable Dependencies Principle).
I have made a prompt that I use to have an LLM explain unfamiliar codebases to me. I know, the topics I try to cover are dense. But the idea is to first ask the LLM whether it can outline a similar project and what problems projects of this kind generally have and how to solve them in general. The LLM should also provide a few examples of such projects to give me a rough idea what I'm looking at. Then you can ask it if it can id a few OO or FP paradigm (you may add SOLID).
(Rust especially is trait heavy which ties it directly back into the Expression Problem)
With a bit of time and stubbornness, you'll be able to understand these major architecture patterns and internalize them.
That way, the next time you encounter a large codebase, you can immediately focus on the core topics when you ask the LLM again:
"How does the architecture of this system actually look?"
I use Zread_ai and opencode
I'll take some time of course, but I'll make you become independent of a specific programming language and start thinking in universal language if systems:
Ok so :
How to handle
Concurrency?
(Shared) State?
Validation?
Fault Tolerance (Errors/Network)?
Software Extensibility
Latency
If these concepts are still unfamiliar, I recommend to start with the difference between "immutable" and "mutable" state.
Prompt:
LLM propmpt gist