Hey, I'm not super technical but I saw this slide from River.
276,000 code changes seems really high to me.
ChatGPT said it means 40% of the code changed in 2024.
Is that legit? How can I check this?
Changes in Bitcoin Code: What's the Real Deal?
10 replies 392 views
You can look it up on GitHub. Just go to the Bitcoin repo and check the insights section. Click on code frequency; you’ll find the data there. But watch out, GitHub struggles with big projects like Bitcoin.
That PDF screenshot is kinda misleading.
1. Not all code is about the protocol; some is for wallet management and local blockchain storage.
2. A developer mentioned that over 70% of changes are just maintenance stuff.
3. I couldn’t find if those "276,000" lines included comments or just code rewrites.
Taproot was the latest big change.
Protocol changes need a fork, right?
We’ve only had a handful in 16 years, from BIP-16 to the latest BIPs for Taproot.
DarkMatrixMember
Posts: 28 · Reputation: 205
#5Jan 10, 2024, 06:48 AM
Bitcoin’s protocol is pretty set in stone. They have to show they're doing something, but honestly, it seems outdated.
swiftdiamondMember
Posts: 224 · Reputation: 87
#6Jan 10, 2024, 09:27 AM
Hey fillippone!
I asked Git about those stats and here’s what I got.
First commit in 2024 was on Jan 3, last one on Dec 31.
Between them, lots of changes happened. Total lines of code? 921,267.
So, according to your info, there were 130K new lines and 80K deleted?
That "276,000 lines of changes" seems way off.
Feels weird since River’s usually legit.
swiftdiamondMember
Posts: 224 · Reputation: 87
#8Jan 12, 2024, 04:50 PM
I agree, River is solid, but yeah, it’s tricky to measure refactoring.
Those insertions and deletions are just numbers.
They could have counted all merged PRs from 2024 for better accuracy.
swiftdiamondMember
Posts: 224 · Reputation: 87
#9Jan 12, 2024, 08:00 PM
My bad for double posting, but I need to clarify something.
EDIT: I figured out how they calculated it.
Jameson Lopp said they used a specific command to get results from commits in 2024.
Don’t forget, Git doesn’t exactly report code changes.
The insertions and deletions might not reflect total code changes.
Like that typo fix you posted, it’s just adding a letter to a comment.
swiftdiamondMember
Posts: 224 · Reputation: 87
#11Jan 12, 2024, 11:19 PM
Yeah, definitely not the best metric.
Git can’t give more precise counts since it’s a pointer-based system.
So, if you modify a line, Git sees it as a deletion and addition.