r/programming • • Mar 27 '23

Twitter Source Code Leaked on GitHub

https://www.cyberkendra.com/2023/03/twitter-source-code-leaked-on-github.html
8.0k Upvotes

717 comments sorted by

View all comments

205

u/lafeber Mar 27 '23

A small API change had massive ramifications. The code stack is extremely brittle for no good reason.

Will ultimately need a complete rewrite.

Elon, 3 weeks ago

33

u/WhipsAndMarkovChains Mar 27 '23

Someone link to the recording from a couple months ago where Musk says a “full stack rewrite” is needed and a former senior engineer from Twitter presses him on the issue. The engineer asks an extremely reasonable question like “what’s wrong with the current stack and what do you want to switch to?” and Musk can’t respond.

20

u/[deleted] Mar 27 '23

11

u/lyzurd_kween_ Mar 27 '23

elon musk is so highly regarded and incompetent when it comes to actual software work, i am shocked he was able to reach the stature he currently has. right place at the right time i guess.

→ More replies (6)

92

u/PM_YOUR_SOURCECODE Mar 27 '23

Ok, so all the engineers who had to pass BS LeetCode interviews/whiteboarding couldn’t write a flexible and maintainable codebase? Is that the conclusion here?

64

u/pale_blue_is Mar 27 '23

As someone who works at an unremarkable company and earns a wage slightly above market value, aren't you talking about basically every silicon valley startup from the past 10 yrs?

17

u/BasicDesignAdvice Mar 27 '23

Those stupid tests are at every company. I work at a household name media company making video games no where near Silicon Valley. Same shit.

221

u/Marrk Mar 27 '23

The conclusion is Musk has no idea what he's talking about

→ More replies (20)

27

u/TheWhyOfFry Mar 27 '23

I mean, it’s very possible that it was a brittle code base before they got well known and could be selective about who they hire. And it’s also possible the v1 api that powered external apps couldn’t be shut down because of the massive backlash it would cause, which could force Twitter to keep some bad code in there.

That said, musk probably just doesn’t understand the language it’s written nor the architecture and fired anyone who understood it. Of course it’s “brittle” when you make totally incompatible changes because you have no idea what you’re doing.

20

u/KagakuNinja Mar 27 '23

As Twitter was becoming more popular, they rewrote the system, moving from Ruby to Scala. Scala is a niche language, and depending on how it is used, can get very hard to understand, especially for people unfamiliar with functional programming.

That said, Twitter devs had a great reputation, and when I interviewed there, I got the impression that they were not FP zealots.

→ More replies (1)

7

u/[deleted] Mar 27 '23

Yeah because lc has nothing to do with actual software engineering and who ever came up with the idea to interview like that needs to be slapped

→ More replies (3)

3

u/marcio0 Mar 27 '23

well, at least whatever error happens is not at O( n2 )

→ More replies (9)

4

u/lazilyloaded Mar 27 '23

for no good reason

Sure, but the bad reason is "because you executive types always want the new features yesterday"

→ More replies (6)