5 ms·
A rant. I apologize. I try to avoid on HN and in general. Faster, yes, but at what cost? I'm so impressed by the Python community, but I'll never quite unders
by mrcwinn 3y ago
A rant. I apologize. I try to avoid on HN and in general.
Faster, yes, but at what cost?
I'm so impressed by the Python community, but I'll never quite understand why they gravitated to... Python itself. It's unbelievable to me that in Mojo's case some of the brightest, most famous engineers have gathered to do incredible computer science work to improve the compute performance of a language that is fundamentally flawed in its performance characteristics for those very applications. It just seems like such a waste.
How on earth did we arrive at this moment?
Chris Lattner is right in his Lex interview: he had to accept that the community was already committed to Python and given that reality, that in turn pre-filtered his available paths. But my god, what if the community had gravitated to a better language [for these purposes] in the first place? How much further along would we be in our tooling and capabilities to deliver value?
Chris, who I admire, loves to talk about language design decisions; loves to talk about how thoughtful they were in the decision-making around Swift; and then in the next breath says, hey whitespace-based scoping doesn't matter, don't worry about these things. Chris all you do is worry about these things, and worry about them for Mojo. He clearly has opinions that he masks about design choices Python has made; otherwise, after all, why the need to make Mojo?
It just seems like at the end of the day, Mojo may be the most technologically advanced lipstick ever to be placed on a pig.
(Edit for grammar, but clearly not for brevity or conciseness. XD)
- geenat 3y agoThe curly brace community already has tons of great choices. Let indent people have their mojo.
- mrcwinn 3y agoI should have deleted that whole section. I know, I know. Sure, in some world, a whitespace character should dictate placement and lifetime in memory. That's my not preferred world, but also different spokes for different folks. :-)
- mrbungie 3y ago> But my god, what if the community had gravitated to a better language [for these purposes] in the first place? How much further along would we be in our tooling and capabilities to deliver value? Better in what regard? Performance? Maybe there are more important things than performance, like ease of use and barriers to entry. People in this space already tackle essentially complex problems, don't throw more accidental complexity in the form of "better" or more performant languages/APIs.
- gostsamo 3y agoif the better languages were actually good, they wouldn't have allowed python to whip their asses. Python won because it was nice and easy. meet your users where they are, not where you want them to be.
- ddragon 3y agoThat would be simplifying too much. There are a lot of external factors for something being popular, like timing, luck, support from big enterprises and leading colleges, inertia and sunk costs. You could argue that does make python better regardless of the language itself but that poster was talking about a hypothetical scenario in which those factors were won by a language better designed for those tasks. Would you use python if most libraries, docs and support were elsewhere just for the language design as is today?
- zogrodea 3y agoRichard Feldman states in a video aiming to explain the popularity of OOP that Python initially had a small community for decades, and that Python's increase in popularity followed a slow and steady increase, which is not true of many other languages like Ruby. That's corroborated by the graph in this article. [0] Based on Python's slow and steady incresae, timing and luck don't seem like good factors for explaining its popularity. The others are debatable though. [0] https://flatironschool.com/blog/python-popularity-the-rise-of-a-global-programming-language/ https://flatironschool.com/blog/python-popularity-the-rise-o...
- ddragon 3y agoI fail to see how timing and luck isn't a factor. It's more than how popular it was when it launched, many of those languages that are allegedly better had a strong timing disadvantage by either not existing or not being mature once the data science boom occurred (including equivalents to libraries like numpy, scipy, matplotlib and theano), allowing python to be the right option then. Any language that missed the timing must now play catch up with a fraction of the resources and completely unproven in the market. Luck is harder to quantify, but at the very least competitors like common lisp didn't have much of it.
- 0cf8612b2e1e 3y agoWhat other scripting languages are even on the table as straight improvements to Python? It seems like there are some potential candidates with improvements in dimension X, but nothing that is an obvious alternative.
- chrislattner 3y agoHey, thanks for your interest. I think it's interesting that you think I don't care about things like whitespace vs braces? In the Lex interview I was kidding around, but I assure you, I do care. Braces are strictly worse than whitespace indentation for several reasons. Brace-based languages: 1) Generally have the "dangling else" set of ambiguities. 2) Some (e.g. C) allow but do not require braces which leads to style debates. The ones that require braces are more verbose. 3) Require more punctuation clutter, and consume more vertical whitespace in practice. 4) ... use braces that are completely redundant with indentation in practice! It's super funny to see people defend curly based languages. Using curlies but not indenting properly is almost always a sign of a bug (e.g. clang has warnings for this sort of thing due to the "goto fail" and other debacles. That said, as you also know, Python compat is not optional for us, so Mojo doesn't actually a choice at all here. I find it amusing though that your post acknowledges thoughtfulness in language design and thinks this is an example of a lapse of judgement. :P -Chris
- alpaca128 3y ago> It's super funny to see people defend curly based languages. Well, that's because they're not really "strictly worse" in every way. I find curly braces helpful for readability and cursor navigation. The latter is only possible with Python by completely parsing the code. Also I don't like reading vertically dense code, so having (almost) empty lines inbetween is fine. All subjective of course, but that's the case for every aspect of language syntax. > Using curlies but not indenting properly is almost always a sign of a bug I don't think anyone criticising Python's syntax cares about the freedom to have inconsistent indentation, that's not the point.
- saagarjha 3y agoCurly braces are very helpful during development, because you can scope code without having to reindent it. It's quite similar to being able to comment out a block of code, which Python happens to also make somewhat frustrating.
- mrcwinn 3y agoChris, Ha! I love your reply. Thank you. I know you care about language design. As I said more or less, that's self-evident, and I'm sorry for taking your whitespace comments too literally. You're the source, after all, not me, so accept my apologies there. It's misinterpretation, but not meant to be a misrepresentation. :-) My comment wasn't meant to be critical of you. Honestly, as a pretty famous engineer, it never even crossed my mind you might read my message. As I said, I know you have to deal with reality to accomplish your goal, and that reality existed before you showed up to take on the challenge. Thank you for all your contributions and good luck on Mojo. Chris
- fancyfredbot 3y agoPeople gravitate to python because "good libraries are all you need". Python is fantastic at lashing things together, and most programming is combining pre-existing functionality.
- pharmakom 3y agoTotally agree. It’s not even the stuff that most people complain about (e.g. whitespace) it’s the poor decisions that in hindsight which limit performance or make correct code harder to write… and we’re totally avoidable in hindsight.
- poulpy123 3y ago> if the community had gravitated to a better language As someone that started to use python for science relatively soon (before numpy), I have to ask: which better language was existing at this time ?