5 ms·
"At Instagram we have hundreds of engineers working on well over a million lines of Python 3." It always amazes me that some of the most popular products aroun
by hacker_9 9y ago
"At Instagram we have hundreds of engineers working on well over a million lines of Python 3."
It always amazes me that some of the most popular products around are built with the worst technology choices. And now they had to build their own static type checker, which slows down random samples of real users, just to shore up the language's weaknesses? Outstanding.
- grandmczeb 9y agoIf lots of successful projects use what you consider the “worst” technology, perhaps the problem is with your perception rather than the technology?
- devoply 9y agoNo the person has a point. Often the weakness of the tech stack are not known ahead of time. Or what is considered a weakness is not a weakness when the choices are initially made. Most developers if they had to do stuff over again would make different choices in one way or another. Also later in the game if you ever get there, when you have capital then certain problems that were caused by the choices made can be resolved a different way... as is the case here.
- alsadi 9y agoThose people believe that the right choice is assembly unless you can write directly in hex /s
- AnimalMuppet 9y agoNonsense. Octal, not hex. (Not totally a joke. My mother wrote in octal before she got an assembler.)
- thechao 9y agoI was taught assembly at the job by an old assembly guru. His first statement to me was something along the lines of: "we'll use an assembler to start with, but it doesn't generate very good code; so, once you're comfortable, we'll hand assemble our machine code".
- AlexCoventry 9y agoWas he just messing with you? What's a case where assembly is not isomorphic to machine code?
- chc 9y agoThat seems like a pretty dodgy metric. Lots of successful construction projects used asbestos, but it is still widely considered a mistake.
- david-cako 9y agoThe downside to using a certain tech stack is technical debt, not a health risk. Technical debt seems like a wise acquisition in moderation, especially for a startup that wants pictures and buttons on screens ASAP, and even more especially when everyone is realizing that it can rather easily be undone when/where it matters with type checker addons and FFI.
- chc 9y agoThat doesn't have anything to do with the question of whether "raw number of successful projects using it" is a good metric for how good something is. Lots of successful companies have made mistakes, and there are even mistakes that many companies in a field made simultaneously (e.g. the XML mania of the early 2000s is not fondly looked back on). I'm not commenting on the specific issue of whether Python creates good trade-offs, just that I think tallying successful companies is a poor measure of a programming language.
- david-cako 9y agoAh, I gotcha, that’s a good point. I still do believe that these decisions for dynamic languages that can later be contorted aren’t just a symptom, but I don’t have any way to prove it.
- david-cako 9y agoAnother comment in this thread makes a very compelling point: perhaps there is some wisdom to using a language that can be initially dynamically typed, and moved over to static typing later on. I don't know. I suspect being half-pregnant is a far bigger issue than the technical debt of dynamic typing, whether it stems from being slower to implement new features, spending time choosing the "correct" tech stacks, or spending more time/money hiring qualified engineers. There's something to be said for the fact that many of the most successful startups in the world are saturated partly or fully with Python and PHP: getting features and new hires off the ground in as little time and money possible is worth its weight in gold. I've always been very much of the opinion that the smartest way to go is making good use of FFI where it counts, and doing everything else in whatever gets code out the door most effectively. This TypeScript/Hack/MonkeyType trend just seems like a very welcome extension of that.
- scrollaway 9y agoLet's make this thread useful instead: Please enlighten the HN community at large: Tell us how you'd build instagram, what your tech choices would be and why Python is the "worst technology choice". (If this goes well maybe you'll get an email from Mike Krieger with the subject line "Here, you do this".)
- fiatjaf 9y agoDo you really think Instagram is a great work of art, that the Instagram codebase is exemplary? I think it could be pure shit -- and indeed a very simple idea. They got big and famous, but it wasn't for dexterity in language choice or coding.
- scrollaway 9y agoIf you believe it to be that simple and low quality a codebase, why does it matter which language they pick?