Announcement

Collapse
No announcement yet.

Fedora 30 Planning To Enable Python Generators By Default

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Fedora 30 Planning To Enable Python Generators By Default

    Phoronix: Fedora 30 Planning To Enable Python Generators By Default

    After being an opt-in feature since Fedora 28, this year's Fedora 30 release will enable Python generators by default to help in crafting packages around Python code...

    Phoronix, Linux Hardware Reviews, Linux hardware benchmarks, Linux server benchmarks, Linux benchmarking, Desktop Linux, Linux performance, Open Source graphics, Linux How To, Ubuntu benchmarks, Ubuntu hardware, Phoronix Test Suite

  • #2
    I may start a flame war here, but I find it fascinating how it seems like programming language sophistication and elegant design seem to be unrelated to the maturity and engineering discipline around the language software repositories and tools.

    So you have a language like Haskell, and all of its fans point out a long list of genuinely awesome features that help you write low defect code in Haskell. And then you have a language like Python, which generally doesn't get a lot of respect from programming language theory enthusiasts. But despite the fact that Haskell is over twenty years old, the stackage or cabal or stack or similar dependency management and project management tools are still struggling to catch up to Python's pip, and Haskell IDE support is still reportedly pretty poor while there are many good choices for Python.

    I'm not trying to knock Haskell or Python. I just find that contrast fascinating. To put my point more succinctly, "Over here we're trying to build the best language in the industry!" "That's nice, but over here we've taken a pretty mediocre language and done spectacular things with it!"

    Comment


    • #3
      Originally posted by Michael_S View Post
      I may start a flame war here, but I find it fascinating how it seems like programming language sophistication and elegant design seem to be unrelated to the maturity and engineering discipline around the language software repositories and tools.

      So you have a language like Haskell, and all of its fans point out a long list of genuinely awesome features that help you write low defect code in Haskell. And then you have a language like Python, which generally doesn't get a lot of respect from programming language theory enthusiasts. But despite the fact that Haskell is over twenty years old, the stackage or cabal or stack or similar dependency management and project management tools are still struggling to catch up to Python's pip, and Haskell IDE support is still reportedly pretty poor while there are many good choices for Python.

      I'm not trying to knock Haskell or Python. I just find that contrast fascinating. To put my point more succinctly, "Over here we're trying to build the best language in the industry!" "That's nice, but over here we've taken a pretty mediocre language and done spectacular things with it!"
      i think you are making a very good observation. and even though this probably has multiple factors that cause it (as every non-trivial phenomenon), Ill say that most of it comes from initial motivations. If you want to create a language, a platform, a framework, or any kind of building block for that matter, and you start with the goal that you want to make it an easy experience for the newcomer, making that your main objective, obviously you'll start making decisions that make that a priority over other concerns(like correctness for instance). OTOH, if you start your project with the idea of focusing of the correctness of the output(the projects built with it), then your decisions will obviously be different after 20 years of so.

      The effects of these two decision will reflect strongly on the communities of ppl they create. You'll have a very strong followers on both sides, but one of those sides will have many ppl who dont have the actual focus on correctness, instead they have the focus on putting the solution(whichever solution that can 'solve' the issue) out there and 'fix' it afterwards if anything breaks(the web development model basically), while the other will put correctness of code and structure first, obviously at the expense of development time. Now, you tell which of those groups will come up with more output, and which one will come out with a higher non-garbage output ratio.

      Comment


      • #4
        Originally posted by Michael_S View Post
        I'm not trying to knock Haskell or Python. I just find that contrast fascinating. To put my point more succinctly, "Over here we're trying to build the best language in the industry!" "That's nice, but over here we've taken a pretty mediocre language and done spectacular things with it!"
        Imperative languages are easier to grok therefore draw a larger community, which both demands and writes tooling. Sometimes I wish Scheme/Racket and other lisps had more attention, but then again, the community and resulting code would change. Maybe it's better to silo the average programmer in Python, like the average user is siloed in Windows, lest they and their needs be unleashed on the rest of us.

        Comment


        • #5
          Originally posted by euler271 View Post
          Now, you tell which of those groups will come up with more output, and which one will come out with a higher non-garbage output ratio.
          Right. But what is fascinating is that while the non-garbage output ratio might be much better for the Haskell or Scala or Idris or similar advanced language community, the Python community total non-garbage output volume is substantially higher. There's tons more trash, but there's so much more useful stuff that for a huge selection of real world uses it makes more sense to reach for Python than the others. That outcome surprises the hell out of me.

          My intuition is that the most disciplined languages with the most sophisticated type systems would have conquered every space in our industry except bleeding edge performance decades ago. And here we are, with PHP as the most popular server side language on the web and Javascript/Node and Python as wildly popular. My intuition was wrong.

          Comment


          • #6
            Originally posted by cynical View Post
            Imperative languages are easier to grok therefore draw a larger community, which both demands and writes tooling.
            Yes. This makes me wonder if Perl6 has real potential. The language supports imperative kluge-something-together-and-go programming, but the type system is pretty sophisticated and if you add type constraints to variables and methods they are enforced. So you can get your Perl6 program out the door with it looking as clunky as a quick and dirty Perl5 program but evolve the code without changing the behavior into something that's 85% of the way to Haskell or maybe 100% of the way to Scala. https://docs.perl6.org/language/haskell-to-p6

            Some other languages like Dart, Typescript, Groovy, Racket, and Clojure core.typed offer the ability to add type constraints to code, but from what I understand the Perl 6 type system is more sophisticated. It has pattern matching guards, function currying, multi-methods, etc... I'm happy to be corrected but my understanding is that the other five options I listed don't have the same full set of features.

            Edit: while I'm promoting Perl 6, I'll add that it improves on the regular expression features of Perl5 and also has a really cool grammar engine for custom parsing and building domain-specific-languages.

            Edit 2: though maybe the future of programming might be the compile-to-js languages. So you hack your thing together in Nodejs/Javascript and then rewrite it incrementally in Scala-js or Haskell-js or similar. Once the whole thing is in Scala or Haskell, you can skip the JS layer.
            Last edited by Michael_S; 02 January 2019, 11:13 AM.

            Comment


            • #7
              https://www.jwz.org/doc/worse-is-better.html makes a good case for aiming for a 50% complete "basically good" implementation over perfection.

              Python is also constantly improving, and still keeps most of its initial simplicity.
              Haskell is aiming to be as perfect as can be, but is very difficult to write a useful piece of software as it forces you to also aim for perfection.
              Which is not a bad thing.

              Python instead makes writing bad applications more work than a "basically good" app. Ah well.

              Comment


              • #8
                Originally posted by Michael_S View Post

                Right. But what is fascinating is that while the non-garbage output ratio might be much better for the Haskell or Scala or Idris or similar advanced language community, the Python community total non-garbage output volume is substantially higher. There's tons more trash, but there's so much more useful stuff that for a huge selection of real world uses it makes more sense to reach for Python than the others. That outcome surprises the hell out of me.

                My intuition is that the most disciplined languages with the most sophisticated type systems would have conquered every space in our industry except bleeding edge performance decades ago. And here we are, with PHP as the most popular server side language on the web and Javascript/Node and Python as wildly popular. My intuition was wrong.
                Sophisticated type systems did take over the world, that's what the OOP revolution was about, and why C++, C#, and Java are the standard for most serious projects in userspace. Haskell, Lisp, and friends haven't become popular because functional languages are hard, and there hasn't historically been a performance benefit to justify the pain. see: https://benchmarksgame-team.pages.de...r/ghc-gpp.html

                Meanwhile much of the interest surrounding Rust is because of it's even more sophisticated type system than what the normal standard bearers (C++, C#, Java) provide, while also providing that performance benefit.

                Comment


                • #9
                  Originally posted by Luke_Wolf View Post

                  Sophisticated type systems did take over the world, that's what the OOP revolution was about, and why C++, C#, and Java are the standard for most serious projects in userspace. Haskell, Lisp, and friends haven't become popular because functional languages are hard, and there hasn't historically been a performance benefit to justify the pain. see: https://benchmarksgame-team.pages.de...r/ghc-gpp.html

                  Meanwhile much of the interest surrounding Rust is because of it's even more sophisticated type system than what the normal standard bearers (C++, C#, Java) provide, while also providing that performance benefit.
                  There is some marketing-speak out there claiming that Haskell can be as fast as C, but aside from a few corner cases in most benchmarks I know that doesn't hold up. But the thing is that PHP, Python, and even Javascript aren't in the same performance category as Java/C# and they're still popular for other reasons. And Java and C# in turn usually don't match C++.

                  To me the killer feature is that, supposedly, if you can become proficient in Haskell it leads to amazing developer productivity and a very low defect rate in the production code. That is, once you climb the learning curve it's the closest we can get to the mythical silver bullet. Still not a silver bullet, but the best the real world can manage. I am not proficient with the language, but I've been interested in it since Tim Sweeney wrote about it in 2006.

                  But to circle back around, it seems intuitive to me that if Haskell really is the best thing our industry can offer then it would be conquering the space occupied by other languages. One Haskell developer would be making libraries and tools equivalent to the productivity of three or four Python developers, and everyone would be jumping on the Haskell wagon because of the progress being made. But instead we see the opposite. Python may not be more productive on a per-developer basis than Haskell, but its popularity is growing rapidly so for every Haskell ecosystem contributor there are 100 Python ecosystem contributors and enough of them do good work to blow Haskell away.

                  I use Haskell as an example, but the same logic applies to Scala (which can be viewed as a Java++/Haskell hybrid) or F# (a typed functional language for .NET) and similar languages.

                  Lisp is a different story. See http://steve-yegge.blogspot.com/2006...able-lisp.html

                  Comment


                  • #10
                    Originally posted by Michael_S View Post

                    There is some marketing-speak out there claiming that Haskell can be as fast as C, but aside from a few corner cases in most benchmarks I know that doesn't hold up. But the thing is that PHP, Python, and even Javascript aren't in the same performance category as Java/C# and they're still popular for other reasons. And Java and C# in turn usually don't match C++.
                    Sure, but the reason most people push Python is that according to their own understanding of things: Python is easy. Which seems to really translate into: Python is simple for simple programs.

                    Javascript effectively has a monopoly on client side scripting on the web, and so it has become a golden hammer for web devs, regardless of it's quality or lack thereof.

                    PHP's popularity has as much to do with WordPress as anything.

                    Java/C# came into popularity and stayed there because they were the first big contenders in the brave new world of OOP that didn't have the complexity that C++ brought in, and so corporations bought into these languages and stayed there, and consequently this is what students are taught when they take programming courses in Computer Science.

                    and C++'s main draw was it's speed and compatibility with C while providing an OOP view of the world.

                    Originally posted by Michael_S View Post
                    To me the killer feature is that, supposedly, if you can become proficient in Haskell it leads to amazing developer productivity and a very low defect rate in the production code. That is, once you climb the learning curve it's the closest we can get to the mythical silver bullet. Still not a silver bullet, but the best the real world can manage. I am not proficient with the language, but I've been interested in it since Tim Sweeney wrote about it in 2006.
                    The problem is, let's say every dev is capable of taking that journey, how many are actually willing to suffer the hardships to reach that end? Unless we start enforcing it at the university level, the answer is not a lot. It would be nice to believe that every dev was willing to spend the time to improve themselves and become the best they could be, but the truth is that devs are lazy and like "easy" answers even if they come back to bite them in the ass later. In Haskell's case it's quite the bar to jump over.

                    Originally posted by Michael_S View Post
                    But to circle back around, it seems intuitive to me that if Haskell really is the best thing our industry can offer then it would be conquering the space occupied by other languages. One Haskell developer would be making libraries and tools equivalent to the productivity of three or four Python developers, and everyone would be jumping on the Haskell wagon because of the progress being made. But instead we see the opposite. Python may not be more productive on a per-developer basis than Haskell, but its popularity is growing rapidly so for every Haskell ecosystem contributor there are 100 Python ecosystem contributors and enough of them do good work to blow Haskell away.

                    I use Haskell as an example, but the same logic applies to Scala (which can be viewed as a Java++/Haskell hybrid) or F# (a typed functional language for .NET) and similar languages.

                    Lisp is a different story. See http://steve-yegge.blogspot.com/2006...able-lisp.html
                    Well sure, if there were zero barrier to entry that might be the case, but let's draw this into an analogy. Let's say that there's 2 restaurants in the world A and B, both of these restaurants cost the same, but B has the most delicious food you might ever taste while A is average fare, however in order to eat at B you must be able to lift an 100lb dumbbell, and demonstrate other feats of physical prowess. Who is going to have more customers? A or B?

                    You're right that the number of people doing python is vastly outpacing the advantage that haskell supposedly brings, but there's a reason for that.

                    Comment

                    Working...
                    X