• noisy_boy 7 hours ago

    I remember reading the Perl O'Reilly book (Introduction to Perl[0]) end-to-end and basically feeling that it all makes sense - ($)calar, (@)rray and % for dictionary (because we have a pair of "o"s representing key/value) and so on. Coming from only writing bash (which is all people around me wrote), it was like a becoming a superhero overnight. I rewrote all my bash scripts in Perl and got high level language features with blazing speed. I relished taking people's bash scripts that took an hour and rewriting them in Perl for them to take barely few minutes (which was objectively terrible performance but I was a novice programmer then and nobody else knew better). I was a hotshot. It was an awesome feeling.

    Later I got another role solely because they couldn't find Perl programmers and I wasn't half bad at it. But this was an actual application written by a bunch of people who wanted to write clever code and it was like handing over the keys to a missile depot to a bunch of arsonists. Many thousands LoC. By the end of it, I was told that we need to move to using Java and I could barely contain my relief.

    For one-off scripts, still nothing flows like Perl. It is the most interesting language I have coded in, bar none.

    [0] correction: Learning Perl, the llama book (thanks @ninkendo)

    • Spooky23 6 hours ago

      You stole my story! :)

      I was a mediocre developer and student in my CS program and actually considered getting out at a few points. I really loved systems and building solutions though, and I ended up becoming a DBA.

      For some reason my mental model resonated with Perl. I was able to use it almost like a writing process, getting my “outline” laid out in Perl and refactoring supplementing with more efficient C code or third party stuff later.

      It was cool, i started fixing data integration issues and automating processes around the databases. Eventually a colleague and I basically built an application that made our DR testing failover and failback processes a two-click event. I left that company long ago and I know a bunch of our stuff ran almost 20 years before the system was migrated to AWS.

      IT is more industrial and efficient these days. That’s not a bad thing, but I had alot of fun being the kid showing the old people what Linux was and gluing all of these systems to orchestrate them. Unfortunately Perl is an artifact of that era.

      • tsumnia 5 hours ago

        I felt the same when I used Python to rewrite some broken/incompatible C code. It didn't save on performance, but it did reignite that hacker mindset with a clear to write language. I show students my Flask sets up and I can see the light bulbs firing off in their brains.

        The older languages may be artifacts of our era of code, but I'm excited to see what the next wave of documented prompting vibe coding will bring.

        I might finally understand what the heck my students' code is doing HA!

      • raffael_de 7 hours ago

        The Camel Book.

        There was something so wonderfully down-to-earth and humane about those O'Reilly books. But actually most IT books had something casually playful and creative about them. A quality you rarely find these days.

        • ninkendo 7 hours ago

          The camel book was “programming Perl” and was more geared towards existing programmers IIRC… there was also the llama book, “learning Perl”, which was maybe what GP was referring to?

          Learning Perl (the llama book) was my first programming book, and it taught me programming in general, not just Perl, and I still think it was an amazing book. Very approachable, helpful to beginners, I read it cover to cover. There’s also “learning Perl objects references and modules”, which is a bit of a sequel to Learning Perl. Those two books helped me land my first gig as a Perl programmer, and started my whole career.

          • noisy_boy 6 hours ago

            Thank you, it was indeed Learning Perl, the llama book.

          • noisy_boy 7 hours ago

            It was the second book that I actually loved. I read it several times, in no particular order, like one just dives into chomping on a fond snack.

            • thm 7 hours ago

              …and sadly because they're already outdated by the time they reach the printing press these days.

              • unixhero 3 hours ago

                Maybe

                But I couldn't understand anything of it.

                Hence I became an economist within cyber security instead.

              • dijit 7 hours ago

                There's so much I can write here, not only do I agree with you - there remains little better for processing streams of text than perl.

                Even PHPs prominence (and ease of use) can be traced back to the parts it borrows from Perl; since the web is just manipulating text after all.

                I went on a similar journey to you. Started with C, moved to bash, then to perl to replace bash scripts, and you're right that it feels like a super power.

                But the most interesting language I've ever coded in was probably Ruby, because it changed the way I look at languages. In Ruby, everything is an object and everything is mutable - this makes the dynamic metascripting possibilities simply absurd.

                I don't advocate for these languages anymore, as Perl is easy to become "write once, read never", in a way that's much worse than bash- but I can't help but feel like we have definitely lost a killer language for text processing. Seemingly nobody writes perl anymore.

                • ajross 3 hours ago

                  > there remains little better for processing streams of text than perl.

                  That's true, but obscures what IMHO is a deeper truth: thinking in perl naturally leads to thinking in "streams of text", which is a kind of general composability that's been largely forgotten in the Unix world.

                  These days every project has it's own giant list of dependencies, it's own conventions about code structure, it's own list of para-toolchain utilities like linters and formatters. Often it even has it's own set of vscode extensions you pretty much have to use.

                  Nothing is just a tool anymore.

                  • ieee2 4 hours ago

                    I do :)

                  • animal531 5 hours ago

                    Ah, back in university I wrote a paper comparing Perl, Python and Tcl/Tk.

                    Tcl was by far the easiest to use, while Perl sat on the other end of the spectrum for both skill needed to write it as well as to just be able to read it.

                    As the mantra goes, "Power, but at what cost?!?"

                    • ajross 3 hours ago

                      Modern python is far more complicated than anything one saw in a perl 5 script back into the day. Type hints, decorators everywhere, big frameworks like numpy that force your problem into particular paradigms. The modern focus on async and iterables has had the effect of turning even simple code "inside out". It's complicated!

                      And what's interesting is that it's complicated in a lot of similar ways, in terms of thought space, as perl was. Perl was great because you could be clever, where you really couldn't in more pedestrian languages.

                      I find (and I'm not sure this is a good thing) that my python output these days feels very clever sometimes...

                    • onionisafruit 6 hours ago

                      Sounds very familiar. For me I was writing batch scripts and the book was Learning Perl on Win32 Systems. Otherwise it’s the same story.

                    • KaiserPro 21 hours ago

                      I took great pride in making readable, maintainable perl.

                      I worked at a VFX place that was held together by loads of perl, written over a good 15 years. Some of it was clever, but most of it was plain readable scripts.

                      The key to keeping it readable was decent code reviews and someone ripping the piss out of you for making unreadable soup.

                      Its all python nowadays, I do miss CPAN, but I don't miss perls halfarsed function args.

                      However for the longest time, the documentation for perl was >> than python. At the time python doc were written almost exclusively for people who knew how to python. Perl docs assumed you were in a hurry and needed an answer now, and if you were still reading by the end assumed you either cared or were lost and needed more info.

                      With the rise of datascience, python has lost its "oh you should be able to just guess, look how _logical_ the syntax is" to "do it like this."

                      • johnisgood 11 hours ago

                        I also found "perlcritic" to be very useful.

                        > perlcritic is a Perl source code analyzer. It is the executable front-end to the Perl::Critic engine, which attempts to identify awkward, hard to read, error-prone, or unconventional constructs in your code. Most of the rules are based on Damian Conway's book Perl Best Practices. However, perlcritic is not limited to enforcing PBP, and it will even support rules that contradict Conway. All rules can easily be configured or disabled to your liking.

                        https://metacpan.org/dist/Perl-Critic/view/bin/perlcritic

                        It helped me a lot. I think every Perl developers should use it, might help to avoid headache later on. Be careful with severity level "brutal" and "cruel" and "harsh", however. I think "gentle" works in many cases. That said, I used "brutal" and I only fixed the legitimate issues. "brutal" helped me write a proper POD, for one, as "gentle" does not complain about that.

                        • cestith 32 minutes ago

                          Perl’s function arguments no longer require you to shift or to access the @_ array. There are even proper argument signatures now. There’s also continuing improvements in putting a one true way to do objects into the core language, so you don’t have to bless a hash, use Moose, or Moo, or use Object::InsideOut (or any of a dozen other non-core modules).

                          All that old code still works, though.

                          • m463 11 hours ago

                            > I took great pride in making readable, maintainable perl.

                            In the past when I used perl, I did the same thing.

                            But I came to learn one thing about perl - its good point is its bad point.

                            When I used it, perl was the highest level language I ever used. It was expressive, meaning I could take an idea in my head, and implement it in perl with the least friction of any language.

                            When I worked with other people's perl, I found they were mindful and cared about what they were doing.

                            But the way they thought was sometimes almost alien to me, so the expression of their thinking was a completely different type of perl, and it was lots less readable to me. And frequently the philosophy of what they wrote was backwards or inside out from what I would do.

                            Now I have replaced perl with python day to day and although implementation of code seems a few steps removed from my thinking, it seems that other people's code is more easily read and understood. (this is just my opinion)

                            • gilleain 7 hours ago

                              As they say, with perl there's more than one way to do it (TMTOWTDI) and with python there is only one way.

                              Both approaches have their merits. Like with maven, where I once saw a question on a forum that was like "how do I do X?" and the reply was basically "You can't, don't try to do so, as that's wrong".

                              • tzs 2 hours ago

                                There is usually more than one way to do it in Python, too. For example most people's Python fizzbuzz seem pretty different from mine:

                                  def fizzbuzz(n, *args):
                                    cur = ['' for x in range(1,n+1)]
                                    for m, postfix in args:
                                      cur = [y+postfix if x%m==0 else y for x, y in zip(range(1,n+1), cur)]
                                    cur = [str(x) if y == '' else y for x, y in zip(range(1,n+1), cur)]
                                    return cur
                                
                                  print("\n".join(fizzbuzz(100, (3, 'fizz'), (5, 'buzz'))))
                              • Shorel 7 hours ago

                                That's an interesting point that could be even more interesting with some examples on both languages.

                              • jstanley 10 hours ago

                                > I don't miss perls halfarsed function args.

                                You mean you don't like writing things like...

                                    sub foo {
                                        my ($a, $b, $c) = shift;
                                
                                ?
                                • KaiserPro 20 minutes ago

                                  Indeed!

                                  It just grinds my gears that _I_ need to check to see if the caller has given me all the required bits. That seems like something the language should do.

                                  I understand that it does give you a lot of flexibility, but Hnnnnnnnnn

                                  (from what I recall object oriented perl doesn't give you this flexibility, but I'm not sure, as I never really did it. )

                                  • oneshtein 10 hours ago

                                      Yes, I hate to write
                                    
                                      sub foo($$$) {
                                        my ($a, $b, $c) = @_;
                                      }
                                    
                                    Where @_ is array of arguments, and ($$$) is function prototype (3 scalars are expected).
                                    • AndrewDavis 10 hours ago

                                      Perl has subroutine signatures now. You can write

                                      sub foo ($x, $y, $x) { ...}

                                      It's just syntactic sugar, so you still can't pass in multiple lists, and the list must be the final parameter.

                                    • AndrewDavis 10 hours ago

                                      Not sure if you've deliberately put in two bugs there haha

                                      1. shift only shifts off the first element.

                                      2. (if classify this as a bug) using $a and $b are frowned upon because they're the default variables when using sort.

                                      • 7952 6 hours ago

                                        Oh wow I had forgotten about default variables. Such a lovely and inscrutable idea.

                                        • jstanley 9 hours ago

                                          Ha, (1.) was deliberate but I'd forgotten (2.)

                                          • sshine 9 hours ago

                                            Yeah, you probably want

                                              my ($x, $y, $z) = @shift;
                                            
                                            :-D
                                            • rurban 6 hours ago

                                              For reference:

                                              Valid is either

                                                 sub () {
                                                   my ($x, $y, $z) = @_;
                                              
                                              or

                                                 sub ($x, $y, $z) {
                                              • kqr 5 hours ago

                                                Why the empty prototype in the first alternative?

                                                • rurban 5 hours ago

                                                  yeah, you could leave that out, but then I have to invent a name

                                                  • kqr 5 hours ago

                                                    Really? Anonymous subroutines/coderefs are defined with sub {} are they not?

                                      • jgrahamc 7 hours ago

                                        Yes, as did I! When I did POPFile (which is 100% Perl) I was really, really careful to make it readable and maintainable.

                                        • AtlasBarfed 12 hours ago

                                          Maybe what we need as programmers for collective professional defense is to only LLM-code in Perl.

                                          At some point when the LLM fails, you'll need a real programmer to figure it out.

                                          But IMO, LLMs are code generation, and code generation always fails at some point when the pile of generated code topples, no matter the language.

                                          The amount of bad enterprise LLM code that will be cranked out in the next few years is going to be fascinating to watch.

                                          • ronniefalcon 6 hours ago

                                            let me guess, MPC?

                                          • CaliforniaKarl 18 hours ago

                                            One thing I wish other languages had was Perl's taint mode: Once enabled, input coming from the outside was "tainted", along with anything you explicitly marked as tainted. If a tainted variable was used to populate another tainted variable (such as by concatenation), the result itself was tainted. If a tainted variable was used in certain ways (such as with the `open` call), the program crashed. The primary way to remove a taint was by running the variable through a regular expression, and using the captured matches (which would not be tainted).

                                            • kqr 9 hours ago

                                              This is "parse, don't validate" as a language feature. Any statically typed language has this, in the sense that you can write your domain logic in terms of a set of "untainted" domain types, and only provide safe conversion functions (parsers) from user input to domain types.

                                              • layer8 7 hours ago

                                                No, they really don’t have this, because for example you can still open() using an arbitrary string as a file name, a string which may have come from unvalidated input. They don’t force you to convert the string to a FileName type and also prove that you have done some sort of pattern-matching on the string.

                                                • kqr 5 hours ago

                                                  That is true. You'd need to expose alternative versions of system functions that deal only in parsed and not raw data, and then prohibit the native variants. A little more ceremony, but also a little more flexibility.

                                                  Edit: It might be easier to instead replace input functions with ones that return TaintedString, unusable as a regular string. But it's easier to write a linter rule that prohibits any unsafe (default) system functions than one which requires safe input functions, I suppose.

                                                  • kstrauser 4 hours ago

                                                    Now I’m imagining a Rust UncheckedString type with a to_string() method that takes a regexp.

                                                • burnt-resistor 18 hours ago

                                                  Ruby does. Normalization of untrusted input isn't taught or discussed enough. Or each platform's regex security.

                                                  Honestly, I think all CS/EE programs should require an OWASP course and that coding should require regular continuing education that includes defensive coding practices for correctness, defined behavior, and security.

                                                  • stouset 11 hours ago

                                                    This was removed in Ruby 2.7. It was neat, but a bit of a blunt instrument.

                                                  • billpg 5 hours ago

                                                    How does that work in practice?

                                                    Suppose the Table family type their son Bobby's name into a form. The Perl program now has a "tainted" string in memory - "Robert'; DROP TABLE Students --".

                                                    The Perl code passes this string through a regex that checks the name is valid. Names can include apostrophes (Miles O'Brien) and hyphens (Jean-Luc Picard) along with spaces and normal ASCII letters, so the regex passes and the string is now untainted.

                                                    • moritzwarhier 3 hours ago

                                                      > The Perl code passes this string through a regex that checks the name is valid

                                                      I think "parse don't validate" doesn't help in this example, but naively the regex would not check whether a name is valid but "extract all parts of the string that are provenly safe".

                                                      Which is not reasonable for SQL statements, so someone invented prepared statements.

                                                      I think the idea is that the Regex parsing forces the programmer to think about what they're doing with the string and what the requirements for the non-tainted variable are.

                                                      For example, a file name string would not allow unescaped directory separators, dots, line breaks, null bytes (I probably got most details wrong here...) and the regex could remove these or extract the substring until the first forbidden character.

                                                      Sure, this cannot prevent mistakes.

                                                      But the idea, I think, is not to have a variable "safeUserName", instead a "safeDbStatement" one.

                                                      • cestith 28 minutes ago

                                                        You should be using DBI or something that builds on DBI to use prepared statements for database interactions. That’s why it’s called the DataBase Interface.

                                                      • amboar 6 hours ago

                                                        gcc's __attribute__((tainted_args)) is pretty handy: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attribute...

                                                        • bornfreddy 11 hours ago

                                                          Nice idea, thank you! I think it should be possible to make a Python object behave in a similar way (crashing when converted to string / ...), need to see if I can make it work.

                                                          In PHP, you can construct objects directly from $_GET/POST (and erase everything from these vars to make sure they are not used directly), then lean on data types to make sure that these values are not used in a wrong place.

                                                        • ben7799 5 hours ago

                                                          Technically I did my first programming in the 80s as a kid. I went to college in the 1990s. I definitely learned Perl and used it.

                                                          However I would say an awful lot of the professionals I was around already thought Perl had a bad smell even in the 1990s. It was definitely looked down up on in academia by then. Maybe not in an IT department or Math department but in the CS department it was. It was used by IT guys, and QA guys, and somebody gluing some tools together. An awful lot of people thought it was unacceptable for it to be in serious production code or anything that had to be long term maintainable or be worked on by a team of people larger than size = 1. Your perception of it definitely came from where you were at the time and how you encountered it. If you were on a team producing software for sale that involved a bunch of people and you had version control and QA and everything Perl was already not your thing.

                                                          • alexpotato 21 hours ago

                                                            As both a long time Perl and long time Python user who has seen both used in production, here are some of my thoughts:

                                                            Perl

                                                            - Was an easy jump from bash to Perl

                                                            - Perl never felt like it "got in the way"

                                                            - was WAY too easy to write "write only code"

                                                            - that being said, I learned Java first and most people found MY Perl code to be very legible

                                                            - regexes as first class citizen were amazing

                                                            - backwards compatible is GREAT for older systems still running Perl (looking at you banks and some hedge funds)

                                                            Python

                                                            - Forced indentation made it MUCH easier to read other people's code

                                                            - everything is an object from day one was much better than "bless" in Perl

                                                            - no standard way of setting up an environment for MANY years hurt

                                                            - sklearn and being taught in universities were real game changers

                                                            • m463 11 hours ago

                                                              > - no standard way of setting up an environment for MANY years hurt

                                                              I will say coming from years of perl that python had a refreshing amount of "batteries included" via the standard library.

                                                              It was only rarely that my code needed "outside help", usually something like requests or numpy.

                                                              I suspect this is because I used python in the same environment as perl, automating unixy kinds of things.

                                                              I suspect "setting up an environment" is because python has been so successful, becoming an enormously broad general language.

                                                              • bigiain 11 hours ago

                                                                Awww, come on. cgi-lib.pl was all you really needed! <smirk>

                                                              • shermantanktop 21 hours ago

                                                                > no standard way of setting up an environment for MANY years hurt

                                                                Serious question: is that solved? I still see a forest of options, some of which depend on each other, and at last count my laptop has 38 python binaries. What's the standard way?

                                                                • mindcrime 20 hours ago

                                                                  There's no "de jure" standard, but uv sure looks like it's on its way to becoming the "de facto" standard.

                                                                  • makeworld 21 hours ago
                                                                    • fuzztester 33 minutes ago

                                                                      What is Astral's business model?

                                                                      • hsbauauvhabzb 21 hours ago

                                                                        It’s hard to call that standard, it’s just the latest hn rust craze idolisation.

                                                                        • sgarland 20 hours ago

                                                                          Sure, but it’s demonstrably better than Poetry, which was the best until uv.

                                                                          If uv isn’t a standard, it’s because not enough people have tried it. It is obscenely good at its job.

                                                                          • slightwinder 8 hours ago

                                                                            uv is young, unstable and still lacking in details. It has multiple updates per month, nearly every week there are significant enhancements and bug fixes. It's not mature enough for being a standard yet, even though, what it already offers is excellent. But let it grow, change needs time.

                                                                            • cozzyd 19 hours ago

                                                                                 standard
                                                                              
                                                                              You keep using that word, I don't think it means what you think it means.
                                                                              • bigiain 11 hours ago

                                                                                "Prepare to die."

                                                                              • nurettin 13 hours ago

                                                                                False dichotomy. Been using pipenv for 8 years. At first it was a bit too slow, but at this moment it gets the job done.

                                                                              • unsnap_biceps 19 hours ago

                                                                                uv is an excellent piece of software regardless of the language used to write it. Really, if you do python, it's worth giving it a try, especially script mode.

                                                                                • hsbauauvhabzb 19 hours ago

                                                                                  Sure but it’s quality or your/my opinion doesn’t make it ‘standard’ even if it will be some day in the future.

                                                                                • zbentley 7 hours ago

                                                                                  Eh, I’m not so sure.

                                                                                  We didn’t see adoption nearly this fast for poetry, pipenv, or conda (or hatch or PDM, but I never saw those as even reaching critical mass in the first place).

                                                                                  Those tools got pretty popular, but it took a long time and most folks found them to have a lot of tradeoffs (miles better than Python’s first party tooling, but still).

                                                                                  I’m not seeing that with “uv”. Other than concerns about Astral’s stewardship model (which could be valid!), I’m not seeing widespread “it works but is hard to use” dissatisfaction with the to the way I do with, say, poetry.

                                                                                  Couple that with uv durably solving the need for pyenv/asdf/mise by removing the pain of local interpreter compilation entirely, and I do think that adds up to uv being fundamentally different in popularity or approach compared to prior tools. Is that “different” the same as “better”? Time will tell.

                                                                                  As to being written in Rust? Shrug. A ton of shops for whom uv has been transformative don’t even know or care what language it’s written in. Being Rust provides, in my opinion, two benefits: a) avoiding chicken-and-egg problems by writing the tool for managing a programming language environment in a different language that is b) not bash.

                                                                                  • zahlman an hour ago

                                                                                    > avoiding chicken-and-egg problems by writing the tool for managing a programming language environment in a different language

                                                                                    I've heard this a lot, but I don't really understand the use case. It seems that people want to do development in Python, want to install and manage third-party Python packages, and know how to use command-line tools, but somehow they don't already have Python installed and would find it challenging to install directly? Building from source on Linux is a standard "get dev packages from the system package manager; configure, make and install" procedure that I've done many times (yes, putting it beside the system Python could break things, but you can trivially set an alternate install prefix, and anyway the system Python will usually be a version that meets the basic needs of most developers). Installing on Windows is a standard Windows installer experience.

                                                                                    Aside from that, people seem to imagine "chicken-and-egg" scenarios with pip making itself available in the environment. But this is a thoroughly (if inefficiently) solved problem. First off, for almost three years now pip has been able to install cross-environment (albeit with an ugly hack; I detail some of this in https://zahlman.github.io/posts/2025/01/07/python-packaging-...). Second, the standard library `venv` defaults to bootstrapping pip into new environments — taking advantage of the fact that pre-built Python packages are zip archives, and that Python has a protocol for running code from zip archives, which the pip package implements.

                                                                                    The real bootstrapping issue I've heard about is https://github.com/pypa/packaging-problems/issues/342 , but this affects very few people — basically, Linux distro maintainers who want to "build" an entire Python toolchain "from source" even though it's all Python code that the runtime could bytecode-compile on demand anyway.

                                                                                  • Ygg2 10 hours ago

                                                                                    You forgot to update your HN craze list. Zig is chic, Rust is out.

                                                                                    • wiseowise 12 hours ago

                                                                                      No, it’s not. Everywhere I see, uv is adopted.

                                                                                      • arcanemachiner 12 hours ago

                                                                                        We're like a year into the uv hype cycle. It needs enough time to make sure it solves the issues of its predecessors.

                                                                                        So what if uv is everywhere you look? So were Poetry, pipenv, and so on. Give it time.

                                                                                        • timeon 9 hours ago

                                                                                          I'm using uv but in corporate places I'm seeing just Conda.

                                                                                      • burnt-resistor 18 hours ago

                                                                                        uv for project management and pipx for user-/system-wide tool installation.

                                                                                        • makeworld 17 hours ago

                                                                                          uv handles that too with "uv tool".

                                                                                        • rossant 20 hours ago

                                                                                          Yes. Try uv and never look back.

                                                                                          • xenator 12 hours ago

                                                                                            You still need pip-tools in uv environment

                                                                                            • nsteel 3 hours ago

                                                                                              What for (honest question) ? Doesn't uv handle locking?

                                                                                        • zahlman 2 hours ago

                                                                                          > Serious question: is that solved?

                                                                                          It depends on what "setting up" means.

                                                                                          Creating an environment, given that the Python binary it will use is already installed, is trivial (standard library functionality since late 2012). So is choosing which environment to use. So is installing pre-built packages, and even legacy source packages are pretty easy (but slow, and installation runs arbitrary code which is entirely needless for these) when they only contain pure Python code. Even dependency resolution is usually not too bad.

                                                                                          The big problems are things like

                                                                                          * building multi-language packages from source locally, because this is expected to set up temporary local build environments (and build tools have to avoid recursion there)

                                                                                          * using external non-Python dependencies (essentially unsolved, and everyone works around this by either vendoring stuff or by not declaring the dependency and failing at runtime) — see https://pypackaging-native.github.io/ for an overview of the problems and https://peps.python.org/pep-0725/ for what they're trying to standardize to deal with it

                                                                                          * dealing with metadata for source packages; in the really general case you have to build the source to get this (although the package-building API now provides a hook so that build backends can specifically prepare metadata). This is mainly because some packages have dependencies that depend on very particular platform details that (apparently) can't be expressed with the "environment marker" scheme in standard metadata (https://peps.python.org/pep-0508/#environment-markers)

                                                                                          * and, of course, figuring out which packages need to be in your environment (Python won't decide for you what your direct dependencies are) and managing that environment over time. The reason all these other tools popped up is because Pip only installs the packages and offers very basic environment inspection; it's only now starting to do anything with lockfiles, for example, now that there is finally a standard for them (https://peps.python.org/pep-0751/).

                                                                                          But if you mean, is there a standard toolchain that does everything and will be officially blessed by the core language developers, then no, you should not ever expect this. There is no agreement on what "everything" entails, and Python users (a large fraction of which don't fit the traditional image of a "developer" at all) have widely varying workflows and philosophical/aesthetic preferences about that. Besides which, the core language team doesn't generally work on or care about the problem; they care about the interpreter first and foremost. Packaging is an arms-length consideration. Good news, though: the Python Packaging Authority (not at all authoritative, and named with tongue firmly in cheek, but a lot of people didn't get that) is stepping up and working on official governance (see https://peps.python.org/pep-0772/).

                                                                                          > at last count my laptop has 38 python binaries

                                                                                          Something has gone very wrong (unless you're on Windows, such that admin rights would be needed to create symlinks and by default `venv` doesn't try). To be clear, I mean with your setup, not with the tooling. You should only need one per distinct version of Python that your various environments use. I'd be happy to try to help if you'd like to shoot me an email (I use that Proton service, with the same username as here) and give more details on how things are currently set up and what you're trying to accomplish that way.

                                                                                        • jjgreen 10 hours ago

                                                                                          Perl was my first scripting language, I occasionally need to run some of those old scripts (15-20 years old), they always run. Python scripts last 6-12 months.

                                                                                          • bell-cot 9 hours ago

                                                                                            So if job security was a high priority for you, ...

                                                                                            • zelphirkalt 8 hours ago

                                                                                              > Python scripts last 6-12 months.

                                                                                              Not, if you know what you are doing.

                                                                                              • alexpotato 7 hours ago

                                                                                                "You're holding it wrong" ;-)

                                                                                                • zahlman an hour ago

                                                                                                  Every Python version is officially supported for 5 years. Tons of useful scripts don't require any dependencies outside the standard library, and I have code from very many years ago that has not been hit by any standard library deprecations (which have been in relatively obscure corners, honestly) and would work fine under current Python. (Of course, it helps that I was a relatively early 3.x adopter.) Conversely, what I write today should generally be backwards-compatible to 3.6 (f-strings are really neat, and `pathlib` semantics greatly improved in that version).

                                                                                                  • zelphirkalt an hour ago

                                                                                                    I mean, if you are not able to make a reproducible virtual environment, by using one of the popular package managers, like Poetry or uv, then yes, you are holding it wrong. If you are relying on requirements.txt merely pinning versions and not transitive dependencies, then yes, you are holding it wrong. In that case it would be a skill issue.

                                                                                                    • zahlman an hour ago

                                                                                                      > If you are relying on requirements.txt merely pinning versions and not transitive dependencies, then yes, you are holding it wrong.

                                                                                                      Even then, if you have the original environment, you may very well not need to re-create it. If you do need to re-create an equivalent for a newer Python version (EOL versions of Python don't just spontaneously vanish, but maybe you upgraded your system or something, or better yet maybe you're planning in advance for that) then you generally can easily create the needed requirements.txt (or, for that matter, a PEP 751 lockfile) from the old environment.

                                                                                              • j45 21 hours ago

                                                                                                Articles that poopoo on one language kind of have a dated all/nothing perspective.

                                                                                                Most languages have a decent enough framework or two that the differences between using them for different use cases may be closer than many folks realize vs whatever we hear about as the new hotness through the grapevine.

                                                                                                A mess can be made in a lot of languages, and a long time ago, it was even easier, except some of that code worked and it didn't get touched for a long time.

                                                                                                • burnt-resistor 18 hours ago

                                                                                                  Toolbox vs. religious zealotry. Sometimes, one has to maintain .bat files, Tcl, F77, or COBOL. Professionals don't whine or wince, but do the job.

                                                                                              • lapsed_lisper 5 hours ago

                                                                                                I worked in Perl for ~2.5 years in the mid-2000s. It wasn't the language for me, but I liked, respected, and am still friends with colleagues who loved it. However, I was always dumbfounded by the experience that none of them could or even professed to be sure of what most code fragments did at a glance, even fragments that only used constructs in the base language. When they worked on existing code, they'd run it, tweak it, run it again, maybe isolate some into a small file to see what it did, look at perldoc, ask questions on IRC, etc. As a Lisp guy, I'm all for interactive & iterative development, but I also like learning tools so as to use them more effectively over time. I didn't find that learning Perl made me more productive with it over time (on a modestly sized, pre-existing code base that needed both maintenance and new feature development), and the Perl lovers I knew didn't seem to mind not having this as part of their work.

                                                                                                Anyhow, toward the end of my time there, I had to interview candidates. Because I came to believe that the above is how one had to work with Perl, I took to asking the ones who said they knew Perl, "Can the reverse builtin reverse a list?" (I won't spoil the answer for you.) Most would answer with "Yes" or "No"; 75% of them were mistaken. Either way I'd ask them "Suppose you weren't confident about that answer. How would you determine the truth?" IIRC, 90% of them said "I'd write this one-liner..." and (I swear) 100% of the one liners would give any reasonable person an impression of an answer that turns out to be incorrect. The ones that said "I'd check the perldoc" were the only ones I'd approve for subsequent interviews.

                                                                                                • animal531 5 hours ago

                                                                                                  I hate when you have code that you can't simply read to understand what it does. I'd like to say that probably 99% of the code that I write embodies that, I refuse to use complicated language constructs wherever I can, even if that makes the code longer.

                                                                                                  When I was a kid and just started working I would still often code with whatever I came up with initially, but then you go back to that 3 months later and you have to throw the whole thing out because it's impossible to maintain or add to.

                                                                                                  On the other hand there are sometimes additions to a language that's just so useful that you have to expand your vocabulary, for example in C# that's happened a few times. One of the notable additions there was LINQ that made manipulating data so much easier. It can become dangerous though, the same as for example with a complicated DB stored procedure.

                                                                                                • jbullock35 20 hours ago

                                                                                                  Leaving aside issues of language design and the emergence of other languages, it's interesting to think about other reasons why Perl lost popularity. Some of you know this history better than I do, but I think that it's now unknown to most HN readers.

                                                                                                  The enormous reason that I see is the insistence, from Larry Wall and others, on a bottom-up "community" transition from Perl 5 to Perl 6. The design process for Perl 6 was announced at a Perl conference in 2000 [1]; 15 years later, almost every Perl user was still using Perl 5. The inability of the Perl community to push forward collectively in a timely way should be taken by every other language community as a cautionary tale.

                                                                                                  Tim O'Reilly made a secondary point that may also be important. For a long time, Perl books were O'Reilly's biggest sellers. But the authors of those titles didn't act on his suggestion that they write a "Perl for the Web" book (really a Perl-for-CGI book). Books like that eventually came, but the refusal of leading authors to write such a book may have made it easier for PHP to get a foothold.

                                                                                                  [1] https://en.wikipedia.org/wiki/Raku_(programming_language)#Hi...

                                                                                                  • daotoad 17 hours ago

                                                                                                    Perl was the perfect language when the majority of people wanting to use it already knew shell, sed, awk, and C.

                                                                                                    It succeeded because it was a beautiful and horrible combination of those tools/languages. If you know those things, Perl is really easy to bang together and generate a webpage or use to automate administrative task.

                                                                                                    Given Larry Wall's education, perhaps we shouldn't be surprised that Perl underwent a linguistic evolution from pidgin[1] to creole[2].

                                                                                                    I came to Perl a bit late, not being a super adept user of Unix and only having written C in school. I'd put myself in the category of Perl developer that was part of the second "creole language" phase of Perl's development. I learned a ton of Unix and got better at C by learning Perl.

                                                                                                    While Perl's mixed nature made it successful, when the world of web development expanded to include more people without the necessary background to benefit from the admixture, it went from asset to hinderance. All that syntax went from instantly familiar to bizarre. A perfect example of this are the file test operators[3].

                                                                                                    The Perl 6 struggles definitely added to the difficulties posed by the changing nature of the web dev community. They created enough uncertainty that tons of people asked themselves "Why should I learn Perl 5 when Perl 6 is just around the corner?". That slowed adoption from in the 2001-2010 timeframe while Python and Ruby grew rapidly.

                                                                                                    Rakulang is kind of magical. Writing it is like using a language given to us by aliens. I wish it was getting more uptake because it is fun and truly mind expanding to write.

                                                                                                    In the end, I think the shifting nature of the community was a larger factor in the decline of Perl than the slow Perl 6 rollout and failure of messaging around it.

                                                                                                    I still love writing Perl 5 and I wish I got to do more of it.

                                                                                                    [1] https://en.wikipedia.org/wiki/Pidgin [2] https://en.wikipedia.org/wiki/Creole_language [3] https://perldoc.perl.org/functions/-X

                                                                                                    • senko 11 hours ago

                                                                                                      Perl 6 definitely sucked up any forward momentum in the community.

                                                                                                      It's become a poster child for how not to do a major transition.

                                                                                                      KDE3/4, GNOME 2/3, Python 2/3 transitions all benefited from this hindsight (still experiencing a lot of pain themselves).

                                                                                                      Raku might be an interesting language (I haven't dug deep), but it's not Perl. Larry et al should've just called it separately from the start and allow others to carry on the Perl torch. They did this too late, when the momentum was already dead.

                                                                                                      Perl 5 was a product of its time, but so was Linux, C, Python 2 or PHP3, and they're still very much relevant.

                                                                                                    • cuddlybacon 19 hours ago

                                                                                                      I had lots of experience writing Perl5 before the company switched to Python3.

                                                                                                      > The inability of the Perl community to push forward collectively in a timely way should be taken by every other language community as a cautionary tale.

                                                                                                      I think this is a good point that I hadn't considered before.

                                                                                                      I think Perl stopped being able to attract new users. There is always going to be users leaving. If they aren't replaced, you will slowly shrink.

                                                                                                      I think the point you raised is part of why they couldn't attract new users. I also think people asked themselves "why chose perl now, if I know I need to re-write when Perl6 comes?" and decided Perl5 was bad choice. I also think the fact Perl had this reputation for being ugly, difficult, and "write only line noise" kept people from even considering it, even if that reputation didn't match production codebases.

                                                                                                      • jasongill 20 hours ago

                                                                                                        I just had to check if it even existed because I was sure that I had a CGI book that focused on Perl from O'Reilly in the late 90's, and sure enough, the book I had was published in 1996 (with a second edition released in 2000).

                                                                                                        Not saying your anecdote is inaccurate, but my perception around that time was that "Learn PHP in 24 Hours" was a lot hotter than O'Reilly's Perl books - so it may have just been luck, marketing, a flashier title, or even just that PHP was better suited for what people wanted to learn and do.

                                                                                                        • lubujackson 16 hours ago

                                                                                                          Slapping PHP tags inside an HTML file was a more natural "outside-in" sort of introduction to programming for the web than Perl's approach. If you already knew some HTML and wanted to add a widget to a page, PHP made that dead simple.

                                                                                                          • bornfreddy 11 hours ago

                                                                                                            Also, you could just FTP the files to the hosted server and it would magically work. No other language that I know of allowed that at the time.

                                                                                                            • timeon 9 hours ago

                                                                                                              It seems to be lost art now. Running it locally however was different story.

                                                                                                          • jbullock35 18 hours ago

                                                                                                            Yes, that's what I had in mind. 1996 was still early—but perhaps the delay allowed PHP to get more of a foothold than it would otherwise have had, especially at such an early stage in the web's development.

                                                                                                          • munificent 20 hours ago

                                                                                                            I think Perl died from a combination of three factors:

                                                                                                            1. The rise of other web languages that did what Perl was good at but better.

                                                                                                            Perl was probably a fine language for sysadmins doing some text munging. Then it became one of the first languages of the web thanks to Apache and mod_perl, but it was arguably never great at that. Once PHP, Python, Ruby, and (eventually) JavaScript showed up, Perl's significant deficiencies for large maintainable codebases made it very hard to compete.

                                                                                                            In many cases, a new, better language can't outcompete an old entrenched one. The old language has an ecosystem and users really don't like rewriting programs, so that gives it a significant competitive advantage.

                                                                                                            But during the early rise of the web, there was so much new code being written that that advantage evoporated. During the dot com boom, there were thousands of startups and millions of lines of brand new code being written. In that rare greenfield environment, newer languages had a more even playing field.

                                                                                                            2. Perl 6 leaving its users behind.

                                                                                                            As a language maintainer, I feel in my bones how intense the desire is to break with the past and Do Things Right This Time. And I'm maintaining a language (Dart) that is relatively new and wart-free compared to Perl. So I can't entirely blame Wall for treating Perl 6 as a blank check to try out every new idea under the sun.

                                                                                                            But the problem is that the more changes you make to the language, the farther you pull away from your users and their programs. If they can't stay with you, you both die. They lose an active maintainer for the core tools they rely on. And you lose all of their labor building and maintaining the ecosystem of packages everyone relies on.

                                                                                                            A racecar might go a lot faster if it jettisons all the weight of its fuel tank, but it's not going to faster for long.

                                                                                                            I think the Perl 6 / Raku folks go so excited to make a new language that they forgot to bring their users with them. They ran ahead and left them behind.

                                                                                                            3. A wildly dynamic language.

                                                                                                            If you want to evolve a language and keep the ecosystem with you while you do it, then all of that code needs to be constantly migrated to the new language's syntax and semantics. Hand-migrating is nightmarishly costly. Look at Python 3.

                                                                                                            It's much more tractable if you can do most of that migration automatically using tools. In order to do that, the tools need to be able to reason in detail about the semantics of a program just using static analysis. You can't rely on dynamic analysis (i.e. running the code and seeing what it does) because it's just not thorough enough to be safe to rely on for large-scale changes to source code.

                                                                                                            Obviously, static types help a lot there. Perl 5 not only doesn't have those, but you can't even parse a Perl program without running Perl code. It is a fiendishly hard language to statically analyze and understand the semantics of.

                                                                                                            So even if the Perl 6 folks wanted to bring the Perl 5 ecosystem with them, doing so would have been extremely challenging.

                                                                                                            I would say this is a case study in a programming language tragedy, but I honestly don't even know if it's a bad thing. It may be that programming languages should have a life cycle that ends in them eventually being replaced entirely by different languages. Perhaps Perl's time had simply come.

                                                                                                            I am grateful for all of the innovative work folks have done on Perl 6 and Raku. It's a cornucopia of interesting programming language ideas that other languages will be nibbling on for decades.

                                                                                                            • zahlman an hour ago

                                                                                                              > But the problem is that the more changes you make to the language, the farther you pull away from your users and their programs. If they can't stay with you, you both die.

                                                                                                              Should people just not make new languages any more?

                                                                                                              Should new languages not bear deep resemblances to existing ones?

                                                                                                              > Hand-migrating is nightmarishly costly. Look at Python 3.

                                                                                                              > It's much more tractable if you can do most of that migration automatically using tools.

                                                                                                              There was and is in fact abundant tool support for this in Python. The `2to3` script shipped with Python and the corresponding `lib2to3` was part of the standard library through 3.11. The third-party `six` compatibility libraries are still downloaded from PyPI more often than NumPy.

                                                                                                              > In order to do that, the tools need to be able to reason in detail about the semantics of a program just using static analysis.

                                                                                                              The experience of these tools users disagrees, from what I've seen. They produce ugly code in places, but it generally passes the tests. Yes, manual fixes are often necessary, but there were source packages published in that era (and it's not like they disappeared from PyPI either) that would detect the Python version in `setup.py`, run the tool if necessary at installation time, and have happy users.

                                                                                                              • hnfong 11 hours ago

                                                                                                                Re #1:

                                                                                                                Perl did not only have mod_perl. It also had the same kind of frameworks that made Ruby and Python great for web development. It was called Catalyst and was production ready around the same time as RoR and Django.

                                                                                                                The real reason why perl failed on this front, IMHO, is that the language makes it super unergonomical to define any nested data structures. In Javascript, Ruby and Python, a list of dictionaries is just some JSON-like syntax: { "x": [...], "y": [...] }

                                                                                                                In perl you have to deal with scalars, references, references to scalar, value references, ... and you have the sigils that mean different things depending on what the variable contains. I mean, I spent significant time writing perl and never figured this out.

                                                                                                                In a world where you just want a CRUD to load/save a piece of structured data, the ones that let you operate on the data and keep your sanity wins.

                                                                                                                • cestith 21 minutes ago

                                                                                                                  Catalyst, Dancer, and Mojolicious actually all exist and have for some time. All of them support PSGI.

                                                                                                                  Mason was available before any of those.

                                                                                                                  There are also other, less popular options as is often the case with any Perl feature or module.

                                                                                                                  • layer8 7 hours ago

                                                                                                                    Yeah, the syntax being “lexically typed” by the sigils while the language not being statically type-checked, was a bit the worst of both worlds.

                                                                                                                    • DonHopkins 10 hours ago

                                                                                                                      I remember encountering exactly that problem in the late 80's when trying to write down a Perl program that I mentally designed by foolishly thinking in terms of Lisp / PostScript (later Python / JavaScript / Ruby) polymorphic arrays with normal object references.

                                                                                                                      I had a clear simple straightforward mental model of how Lisp and PostScript references and also C pointers worked, which only misled and confused and disappointed me when thinking about Perl:

                                                                                                                      https://donhopkins.medium.com/the-shape-of-psiber-space-octo...

                                                                                                                      When I sat down and tried to type my simple straightforward design in as Perl, I suddenly realized that you can't have a reference to something that doesn't have a name, and that Perl name based references, as much as they masqueraded as C or C++ "&" syntax that takes the address of an object, were a TOTALLY DIFFERENT THING.

                                                                                                                      Perl loved to cherry pick and amalgamate the syntax of other languages (usually terrible languages like bash and awk), presumably to "help people who know that language learn Perl easily", but without any of the semantics, which actually makes it MUCH harder to learn, because "&" LOOKS like C but behaves completely differently and is much more limited and quirky.

                                                                                                                      You don't have to assign a C value to a global variable in order to take its address.

                                                                                                                      The syntax and choice of sigils isn't the hard part about learning a language, and if you get the semantics wrong, imitating just the shallow surface syntax of another language that got the semantics right only confuses and disappoints.

                                                                                                                      When you haphazardly mix and match the "syntactic sugar" of many poorly designed languages together into a discordant stew of artificial sweeteners with bizarrely different semantics, you get "syntactic syrup of ipecac".

                                                                                                                      Pre-Perl 5 (Perl 4 and earlier):

                                                                                                                      References were purely symbolic, built on typeglobs and package-variable names. You could only alias or refer to a variable that lived in the symbol table; there was no way to grab a pointer to a literal or temporary value, and you couldn't take a reference to a lexical (my) variable under strict. This made nested or nameless data structures effectively impossible without heavy manual bookkeeping.

                                                                                                                      Perl 5.0 (October 1994) — Hard references and anonymous structures:

                                                                                                                      Perl 5 finally introduced true, first-class references via the backslash operator (\) and the anonymous data constructors: [ … ] for arrays and { ... } for hashes. This let you write things like:

                                                                                                                        my $tree = { name => "root", children => [ { name => "leaf" } ] };
                                                                                                                      
                                                                                                                      without ever giving the inner hash or array a global name.

                                                                                                                      Explicit dereferencing, context-sensitivity, and autovivification:

                                                                                                                      Even with hard references, you must unpack them explicitly ($ref->[0], $href->{key}), and Perl’s context rules (scalar vs. list vs. void) can still be tricky. Perl’s autovivification feature (auto-creation of nested hashes/arrays on first dereference) eases some boilerplate—but can also surprise newcomers used to more explicit models.

                                                                                                                      How Perl compares to Lisp, PostScript, JavaScript, Ruby, Python, etc:

                                                                                                                      Lisp: Lists are built from cons cells and can be manipulated directly as first-class values, e.g. (list 1 2 (list 3 4)).

                                                                                                                      PostScript: Arrays ([1 2]) and dictionaries (<< /Key (Value) >>) are literal, nested, and don’t require separate pointer syntax.

                                                                                                                      JavaScript / Ruby / Python: All provide JSON-style literals ([1,2,[3,4]], {"x":1,"y":[2,3]}) and let you dive into nested structures without ever writing a backslash or sigil beyond the top-level container.

                                                                                                                      By not getting references right from day 1, then reluctantly iterating over decades on experimental hacks and after-the-fact syntactic baggage layered on top of the initial terrible design, Perl made trade-offs that cost much more than they saved from the self-inflicted problems they were trying to solve.

                                                                                                                      Fragmented syntax: Multiple dereferencing forms and feature-gated tweaks (postfix deref, autovivification pragmas) splinter Perl into a patchwork of behaviors.

                                                                                                                      Surprise side-effects: Autovivification can silently spawn large, unused data structures, leading to hidden memory/performance hits.

                                                                                                                      Subtle bugs: Context-sensitive rules (when autovivify, when not) remain a common gotcha, even for veteran Perl hackers.

                                                                                                                      Compatibility drag: Supporting both legacy 5.x versions and modern features forces extra version-checks, boilerplate, and warning squelches.

                                                                                                                      Cognitive overhead: Juggling backslashes, sigils, and varied deref styles demands a more fragmented mental model than the uniform list/map syntax of Lisp-style or JSON-based languages.

                                                                                                                      "The unspoken, right brain constraint here is that the complexity introduced by a solution to a design problem must be somehow proportional to the problem's importance." -Guido van Rossum

                                                                                                                      Edit: Of course Perl finally apes JSON-style literal syntax almost verbatim, but still has the old bad semantics, and getting there plastered over deep complexity you still have to cope with:

                                                                                                                      Feature-gated syntax: New deref forms (postfix, slices) require pragmas or newer Perl versions.

                                                                                                                      Autovivification surprises: Nested lookups can silently create unused data, bloating memory.

                                                                                                                      Multiple deref styles: Backslashes, braces, arrows and sigils—each with its own context rules—fracture your mental model.

                                                                                                                      Legacy support: To run on <5.24, you need version checks, warning silences, or to avoid modern sugar altogether.

                                                                                                                      Hidden complexity: Under the JSON-like literals lies a maze of sigils, contexts, and edge-case behaviors—far from the uniform simplicity of Lisp / PostScript / JS.

                                                                                                                      "Many, if not most" isn't good enough, because the edge cases always come back to bite you. You can't just rearrange the deck chairs on the Titanic and expect the ship not to sink. And sank it did, a long time ago.

                                                                                                                      • cestith 20 minutes ago

                                                                                                                        > I suddenly realized that you can't have a reference to something that doesn't have a name

                                                                                                                        This is untrue though.

                                                                                                                        • serallak 9 hours ago

                                                                                                                          > JavaScript / Ruby / Python: All provide JSON-style literals ([1,2,[3,4]], {"x":1,"y":[2,3]})

                                                                                                                          The Perl syntax for this is pretty similar:

                                                                                                                          [1,2,[3,4]], {"x", 1,"y", [2,3]}

                                                                                                                          that can also be written, with a bit of syntactic sugar:

                                                                                                                          [1,2,[3,4]], {x => 1, y => [2,3]}

                                                                                                                          For many, if not most, cases, given a Perl data structure, the round trip "Perl -> JSON -> Perl" is transparent.

                                                                                                                      • DonHopkins 11 hours ago

                                                                                                                        Python's soul is "Pythonic", which stayed pure from Python 2 to Python 3, but Perl's soul was "Pearl-ick", and Perl 6 had a totally different kind of "ick" than Perl 5 did.

                                                                                                                        Perl's language design fetishizes solving self-inflicted puzzle after puzzle after puzzle.

                                                                                                                        https://www.artima.com/weblogs/viewpost.jsp?thread=147358

                                                                                                                        Language Design Is Not Just Solving Puzzles

                                                                                                                        by Guido van Rossum, February 10, 2006

                                                                                                                        Summary: An incident on python-dev today made me appreciate (again) that there's more to language design than puzzle-solving. A ramble on the nature of Pythonicity, culminating in a comparison of language design to user interface design.

                                                                                                                        Some people seem to think that language design is just like solving a puzzle. Given a set of requirements they systematically search the solution space for a match, and when they find one, they claim to have the perfect language feature, as if they've solved a Sudoku puzzle. For example, today someone claimed to have solved the problem of the multi-statement lambda.

                                                                                                                        But such solutions often lack "Pythonicity" -- that elusive trait of a good Python feature. It's impossible to express Pythonicity as a hard constraint. Even the Zen of Python doesn't translate into a simple test of Pythonicity.

                                                                                                                        In the example above, it's easy to find the Achilles heel of the proposed solution: the double colon, while indeed syntactically unambiguous (one of the "puzzle constraints"), is completely arbitrary and doesn't resemble anything else in Python. A double colon occurs in one other place, but there it's part of the slice syntax, where a[::] is simply a degenerate case of the extended slice notation a[start:stop:step] with start, stop and step all omitted. But that's not analogous at all to the proposal's lambda <args>::<suite>. There's also no analogy to the use of :: in other languages -- in C++ (and Perl) it's a scoping operator.

                                                                                                                        And still that's not why I rejected this proposal. If the double colon is unpythonic, perhaps a solution could be found that uses a single colon and is still backwards compatible (the other big constraint looming big for Pythonic Puzzle solvers). I actually have one in mind: if there's text after the colon, it's a backwards-compatible expression lambda; if there's a newline, it's a multi-line lambda; the rest of the proposal can remain unchanged. Presto, QED, voila, etcetera.

                                                                                                                        But I'm rejecting that too, because in the end (and this is where I admit to unintentionally misleading the submitter) I find any solution unacceptable that embeds an indentation-based block in the middle of an expression. Since I find alternative syntax for statement grouping (e.g. braces or begin/end keywords) equally unacceptable, this pretty much makes a multi-line lambda an unsolvable puzzle.

                                                                                                                        And I like it that way! In a sense, the reason I went to considerable length describing the problems of embedding an indented block in an expression (thereby accidentally laying the bait) was that I wanted to convey the sense that the problem was unsolvable. I should have known my geek audience better and expected someone to solve it. :-)

                                                                                                                        The unspoken, right brain constraint here is that the complexity introduced by a solution to a design problem must be somehow proportional to the problem's importance. In my mind, the inability of lambda to contain a print statement or a while-loop etc. is only a minor flaw; after all instead of a lambda you can just use a named function nested in the current scope.

                                                                                                                        But the complexity of any proposed solution for this puzzle is immense, to me: it requires the parser (or more precisely, the lexer) to be able to switch back and forth between indent-sensitive and indent-insensitive modes, keeping a stack of previous modes and indentation level. Technically that can all be solved (there's already a stack of indentation levels that could be generalized). But none of that takes away my gut feeling that it is all an elaborate Rube Goldberg contraption.

                                                                                                                        Mathematicians don't mind these -- a proof is a proof is a proof, no matter whether it contains 2 or 2000 steps, or requires an infinite-dimensional space to prove something about integers. Sometimes, the software equivalent is acceptable as well, based on the theory that the end justifies the means. Some of Google's amazing accomplishments have this nature inside, even though we do our very best to make it appear simple.

                                                                                                                        And there's the rub: there's no way to make a Rube Goldberg language feature appear simple. Features of a programming language, whether syntactic or semantic, are all part of the language's user interface. And a user interface can handle only so much complexity or it becomes unusable. This is also the reason why Python will never have continuations, and even why I'm uninterested in optimizing tail recursion. But that's for another installment.

                                                                                                                      • contingencies 20 hours ago

                                                                                                                        perl5 -> php3 here. I'd say PHP won for the following reasons: 1. Easier to set up. 2. More homogeneous environment which meant easier deployment across the hosts of the day. 3. More secure (a bit). 4. Unicode actually worked. 5. Far more logical syntax: did not have to man perldsc[0] every time you wanted a data structure of greater depth than a monodimensional hash or array. 6. Language features like scalars which made programming easier. 7. Often less files... it was designed to be embedded inside of HTML instead of generating it.

                                                                                                                        [0] https://perldoc.perl.org/perldsc

                                                                                                                        • zhoujianfu 11 hours ago

                                                                                                                          I made the switch from Perl to php mostly because php executed a lot faster (without having to figure out any weird stuff like modperl) and I loved the little convenience functions just built-in like “strtoupper” and the date formatting stuff!

                                                                                                                      • welpo 21 hours ago
                                                                                                                        • gortok 6 hours ago

                                                                                                                          Perl was the first language I learned, because my local books-a-million, in the year 2000, had basically the entire O’Reilly Perl series deeply discounted ($5.99 to $9.99, a steal for a college freshman), and so I learned Perl.

                                                                                                                          The writing of the O’Reilly Perl books had this micheviousness to them that is also reflected in the language itself. It espoused an apparent simplicity in doing simple things, like reading from a file or taking user input, that languages like C++ had much more ceremony around. Likewise, when I used it to create a compliance test generator for a company I worked for, it took me a few days to write something that would take their source questions and answers and generate an entire website that folks could use to give exams and certifications for regulatory compliance.

                                                                                                                          To this day, I have not found any other language that makes text processing as easy as it was in Perl, and given how much of our work is processing text and strings, I’m still a little surprised other languages haven’t made it as easy as Perl did.

                                                                                                                          • ProofHouse 3 hours ago

                                                                                                                            Vibe coders who I love that it exists and they exist, are what annoy me most. They don’t know what they don’t know and now they think they’re Snr devs when most don’t even know what SQL means. They others saying ‘I’m a programmer’ chest out, like have some humility jeez. Plunging a toilet doesn’t make me a plumber

                                                                                                                            • inoffensivename 5 hours ago

                                                                                                                              I was a young teen when the world wide web became a thing, my Dad to gave me a copy of the camel book. I used Perl to write everything... A message board, a stats website for a MUD I was playing on, basically anything I could think of to drop in that cgi-bin directory.

                                                                                                                              All of my code was garbage of course, but it was an incredible amount of fun, a very valuable learning experience.

                                                                                                                              I miss those days, but that probably has less to do than the programming language and more to do with the carefree days. :-)

                                                                                                                              • kqr 11 hours ago

                                                                                                                                A lot of people in this thread speculate that Raku (formerly "Perl 6") killed Perl. But I have yet to see convincing first hand accounts confirming that.

                                                                                                                                I certainly don't believe it. Everyone I talked to at the time who worked with Perl knew it would not go away: humanity had chained too much of the infrastructure of the internet to it. Someone would have to maintain it for many years to come, even if Larry's new experiment became a wild success. (Already back then people seemed skeptical of the experiment and hung back with Perl 5 waiting to see what came out of it before paying too much attention.)

                                                                                                                                I still struggle to understand why Perl went out of favour[1] but I think what another commenter wrote here might come close: for Unixy folks who know shell, C, awk, sed, Vim, etc. Perl is a natural extension. Then came a generation of programmers brought up on ... I don't know, Visual Basic and Java? and these were more attracted to something like Python, which then became popular enough to become the next generation's first language.

                                                                                                                                [1]: As someone who knows me might understand: https://entropicthoughts.com/why-perl

                                                                                                                                • gwd 10 hours ago

                                                                                                                                  > Everyone I talked to at the time who worked with Perl knew it would not go away

                                                                                                                                  But what about people who didn't work with Perl, or only used it as a side thing? I know I personally put off deepening my superficial knowledge of Perl 5 in the early 2000's, in anticipation of "Perl 6". The Osbourne Effect is a real thing.

                                                                                                                                  EDIT Or, companies starting major new projects, and deciding what language to write it in? It's one thing to say, "Perl 5 will be supported for a long time, we don't need to migrate our existing projects off it." It's another thing to say, "We want to start a new project; should we start it in Perl 5, which will become 'legacy' in a year or two when Perl 6 comes out? Or should we write it in Python?"

                                                                                                                                  https://en.wikipedia.org/wiki/Osborne_effect

                                                                                                                                  • bakuninsbart 10 hours ago

                                                                                                                                    There were many daggers making the Perl Community bleed:

                                                                                                                                    1. Enterprise Development

                                                                                                                                    Java et Al led to a generation of developers working further from the kernel and the shell. Professionalization of the field led to increased specialization, and most developers had less to do with deployment and management of running software.

                                                                                                                                    Tools also got much better, requiring less glue and shifting the glue layer to configs or platform specific languages.

                                                                                                                                    Later on, DevOps came for the SysAdmins, and there's just much less space for Perl in the cloud.

                                                                                                                                    2. The rise of Python

                                                                                                                                    I would put this down mostly to universities. Perl is very expressive by design, in Python there's supposedly only "one right way to do it". Imagine you're a TA grading a hundred code submissions; in Python, everyone probably die it in one of three ways, in Perl the possibilities are endless. Perl is a language for writing, not reading.

                                                                                                                                    3. Cybersecurity became a thing

                                                                                                                                    Again, this goes back to readability and testability. Requirements for security started becoming a thing, and Perl was not designed with that in mind.

                                                                                                                                    4. The Web was lost to Rails, PHP, then SPAs

                                                                                                                                    I'm less clear on the why of that, but Perl just wasn't able to compete against newer web technologies.

                                                                                                                                    • cestith 18 minutes ago

                                                                                                                                      You could write good-quality secure code in Perl, but the level of dynamism in the implementation and the fact that there’s only the one main implementation means there’s not much hope of quality static analysis.

                                                                                                                                    • johnisgood 11 hours ago

                                                                                                                                      I agree with "for Unixy folks who know shell, C, awk, sed, Vim, etc. Perl is a natural extension. Then came a generation of programmers brought up on ... I don't know, Visual Basic and Java? and these were more attracted to something like Python.".

                                                                                                                                      I believe this, too.

                                                                                                                                      I do not use Python. I would rather use Perl (!), Tcl, Lua (!), Go (!), C (!), OCaml, Erlang / Elixir, and Factor / Forth, and very rarely Common Lisp (SBCL). I do not like Java / Kotlin and related languages. That said, I started with shell scripts, and then probably a little bit of Perl and Tcl, and very often C because back when I was a kid I was modding ioquake3 forks that are written in C.

                                                                                                                                      • sirtaj 11 hours ago

                                                                                                                                        As someone who shifted from a lot of perl to a lot of python in the early 2000s, it was because the same shortcuts that made perl really great for system "archaeo-devops" scripting made it difficult to read others' code and to write anything larger than a couple of files. I still use grep, awk, sed, cut etc etc a ton, just not perl.

                                                                                                                                        I wouldn't say I was brought up on Visual Basic though. It was not a language that taught structured programming at all.

                                                                                                                                        • layer8 7 hours ago

                                                                                                                                          Even C++ people seemed to favor Python, because of its similar object model.

                                                                                                                                          • a-french-anon 10 hours ago

                                                                                                                                            Better/less worse AND more accessible languages killed Perl. And I say that as someone who knows POSIX sh/awk/sed pretty well; which means using them in constant disgust of the ubiquitous UNIX braindamage.

                                                                                                                                            It's not without reasons that the UNIX guys did Plan 9 afterwards, let me tell you.

                                                                                                                                            • DonHopkins 10 hours ago

                                                                                                                                              "Looking like sh/awk/sed" is not the big win Perl evangelists thought it was. Quite the opposite!

                                                                                                                                              People who have actually used sh/awk/sed know quite well how terrible they are.

                                                                                                                                              I remember Perl evangelists bragging about "associative arrays" as if they were God's Gift to Humanity that no other language could touch, only because they knew no other language. Not even realizing how much more limited Perl's associative arrays were because of its complete lack of reasonable reference semantics.

                                                                                                                                            • DonHopkins 10 hours ago

                                                                                                                                              > Everyone I talked to at the time who worked with Perl knew it would not go away

                                                                                                                                              And they were wrong. Perl went away a long time ago.

                                                                                                                                              • kqr 8 hours ago

                                                                                                                                                Not true. I'm sure Perl is one of the most widely installed languages in the world, by virtue of (still!) being a system component in various unices. (Maybe even macOS?)

                                                                                                                                            • altacc 21 hours ago

                                                                                                                                              > But perhaps the lesson of Perl is timeless. It asks us to be less precious—and more human—when it comes to programming languages and their design. Only then might we be able to bridge the gap between us and the machines.

                                                                                                                                              I'm not clear which way the author thinks this works but having started coding in the 90s I feel that with Perl you had to try to understand the quirks of language and the language didn't try to reach out to programmers to make things easy. Whereas other coding languages aim to be intuitive, with clearer syntax, more logical naming and frameworks to obscure complexity, which to my mind is a better way to bridge the gap between us and "the machines".

                                                                                                                                              • blu3h4t 10 hours ago

                                                                                                                                                The first thing I think of when thinking of Perl is anything but humble, not because Perl monks aren’t humble, they certainly are, they even inspired rubys we are humble cause hi is humble I suppose :D but like I said elsewhere Perl is like nineties music its simply the best, so in my eyes Perl programmers are (unix) greybeards and the most expert you can imagine, so don’t think they could be as humble cause the level of the competency could allow quite some hubris. :D Anyway this is the analogy I see with programming languages and Linux distros, Slackware was created for lisp and its KISS principle later manifested in clojure. Early Debian was released with same Perl versions as the learning Perl book. And both have heavy emphasis on reproducibility and testing. And redhats and ibms other business is Java and redhats ceo even went to work on unity a mono fork or something. So you Perl came from Unix but it shaped Linux and by extension floss world pretty much. It’s like an elder who knows all the answers but nobody asks. Edit: ah and yes Larry was right about timtoady indeed, it can be Perl or Python or whatever :D

                                                                                                                                                • cozzyd 21 hours ago

                                                                                                                                                  Our experiments use some web services written in Perl (DocDB). The great thing compared to python is they they work for years untouched, through many system updates. Stuff written in Python bitrots fast (using MoinMoin for a wiki was a terrible idea, in retrospect...)

                                                                                                                                                  • finaard 21 hours ago

                                                                                                                                                    > If I had to choose a language that is furthest from Perl, it might be Lisp.

                                                                                                                                                    The two languages I enjoy the most are Perl and Lisp - and the majority of my non-work related coding is split between those two.

                                                                                                                                                    • cestith 12 minutes ago

                                                                                                                                                      Indeed Perl has true lambdas and full closures and has for many many years. There’s no GIL. It supports multi-process programming, event-driven programming, and multithreading. It has optional objects. Code can be, but doesn’t have to be, written in prefix with surrounding parentheses. It can feel very natural for people coming from some form of Lisp.

                                                                                                                                                      Unfortunately it doesn’t do automatic tail call elimination but that’s a tooling limitation more than a language limitation.

                                                                                                                                                      • ddellacosta 21 hours ago

                                                                                                                                                        Given that Matz considers both Perl and Lisp an influence, what's your take on Ruby? If homoiconicity is something you care about it's probably dissatisfying, but it's got a lot of very functional aspects at the same time.

                                                                                                                                                        • lambdaba 20 hours ago

                                                                                                                                                          "Ruby is the love child of Lisp and Smalltalk, raised by Perl the eccentric nanny" - Josh Susser

                                                                                                                                                      • throwanem 21 hours ago

                                                                                                                                                        I believe Perl was first called "the duct tape of the Internet" about 20 years ago.

                                                                                                                                                        Ever tried to deal with 20-year-old duct tape?

                                                                                                                                                        • cestith 16 minutes ago

                                                                                                                                                          It’s also been called a Swiss Army chainsaw. I even have that t-shirt.

                                                                                                                                                          • throwanem 14 minutes ago

                                                                                                                                                            Oh, I know. It lives up to the name, too: like all Victorinox products, it's the wrong tool to use for everything it purports to do well, along with what it doesn't.

                                                                                                                                                          • masklinn 9 hours ago

                                                                                                                                                            I’ve seen Julian when he gets pieces which have been duct taped. He’s not a happy camper.

                                                                                                                                                            • DonHopkins 7 hours ago

                                                                                                                                                              You can't fix broken mugs with duct tape. ;)

                                                                                                                                                              >Partway through, Jon Orwant comes in, and stands there for a few minutes listening, and then he very calmly walks over to the coffee service table in the corner, and there were about 20 of us in the room, and he picks up a coffee mug and throws it against the other wall and he keeps throwing coffee mugs against the other wall, and he says "we are fucked unless we can come up with something that will excite the community, because everyone's getting bored and going off and doing other things".

                                                                                                                                                              https://en.wikibooks.org/wiki/Raku_Programming/Perl_History#...

                                                                                                                                                              Intermission: The Jon Orwant Mug-Throwing Incident in 2000

                                                                                                                                                              By 2000, it was evident that Perl needed an infusion of life:

                                                                                                                                                              "The [P5P / Perl Conference] meeting was originally a gathering of Chip Salzenberg, Jarkko Hietaniemi, Elaine Ashton, Tim Bunce, Sarathy, Nick Ing-Simmons, Larry Wall, Nat Torkington, brian d foy and Adam Turoff, brougt together to draft a constitution of sorts since the community seemed to be fragmenting. Jon showed up to the meeting late and found us talking about the community and started throwing things to express his discontent with how perl itself was stagnating, possibly even dying, and that we should be talking about reviving Perl. The cup incident was planned theatre from what I was told later. So, it was already a fait accompli but the tantrum was it's outing." [1]

                                                                                                                                                              https://www.nntp.perl.org/group/perl.packrats/2002/07/msg3.h...

                                                                                                                                                              Andrew.Savige@ir.com [Andrew.Savige@ir.com] quoth:

                                                                                                                                                                *>I am interested to learn more about this incident.
                                                                                                                                                                *>What this really the catalyst for the current Perl 6 development?
                                                                                                                                                              
                                                                                                                                                              Well...calling it a catalyst may be too dramatic a word. The meeting was originally a gathering of Chip Salzenberg, Jarkko Hietaniemi, myself, Tim Bunce, Sarathy, Nick Ing-Simmons, Larry Wall, Nat Torkington, brian d foy and Adam Turoff, brougt together to draft a constitution of sorts since the community seemed to be fragmenting. Jon showed up to the meeting late and found us talking about the community and started throwing things to express his discontent with how perl itself was stagnating, possibly even dying, and that we should be talking about reviving Perl. The cup incident was planned theatre from what I was told later. So, it was already a fait accompli but the tantrum was it's outing.

                                                                                                                                                                *>How many mugs were broken?
                                                                                                                                                              
                                                                                                                                                              only one. 5 were thrown but they were tough :)

                                                                                                                                                                *>Were they coffee mugs or coffee cups?
                                                                                                                                                              
                                                                                                                                                              Coffee mugs. Standard hotel issue.

                                                                                                                                                                *>What colour were they?
                                                                                                                                                              
                                                                                                                                                              White.

                                                                                                                                                                *>Did anyone keep some broken cups for later display in musuem?
                                                                                                                                                              
                                                                                                                                                              No :)

                                                                                                                                                                *>Did anyone photograph the incident or broken cups?
                                                                                                                                                              
                                                                                                                                                              No :) Thank goodness as I'd hate to have a photo of me diving under the table.

                                                                                                                                                              https://web.archive.org/web/20110716115800/http://www.spider... is about as close to a photo of this as you'll find :)

                                                                                                                                                              e.

                                                                                                                                                              • throwanem 3 hours ago

                                                                                                                                                                There's a current in human affairs to be sure. By 2000 it had just about washed Perl as far east as Memphis, where it became the first language in which I considered myself to be doing "real programming," and not long after the springboard into the first 20 years of an engineering career whose last 20 look likely to embody a role Tim Leary might have purported to recognize. (The last time having a genuine conversation with a computer was really part of the public vernacular, so was he, of course! Wrong about everything as always, but sometimes provocatively so.)

                                                                                                                                                                I'm not sorry to have stopped working in Perl, broken cups or no; thinking back on my time with it puts me forcibly in mind of what I believe to have been Wirth's comments on the hazards of early exposure to BASIC, and "The Rails' Progress" in the late 2000s and after I would nominate as the corresponding farce.

                                                                                                                                                              • andrewstuart 21 hours ago

                                                                                                                                                                Perl was later called “executable line noise”.

                                                                                                                                                                • alexpotato 21 hours ago

                                                                                                                                                                  "Perl is a write only language"

                                                                                                                                                              • corytheboyd 20 hours ago

                                                                                                                                                                Mention of Perl will always reminds me of that time I put Perl in a PR at a Ruby shop. It was a beautiful, portable little piece of code that they made me take outside and shoot in the back of the head. Fair enough, but I will never get over it lol. I don’t even write Perl scripts for personal work anymore, I use python (only because uv makes it not awful), but it’s not about that!

                                                                                                                                                                • Western0 3 hours ago

                                                                                                                                                                  I use perl , still is fast and very intuit for writing small code (but not for reading it after a week)

                                                                                                                                                                  • weare138 32 minutes ago

                                                                                                                                                                    Perl is a messy, maddening programming language

                                                                                                                                                                    Only because people kept writing horrible code and using Perl as an excuse. Perl is like C, your code is as readable and maintainable as you choose to make it. It's like that old saying about blaming your tools. Just stop writing crap code.

                                                                                                                                                                    • paxys 21 hours ago

                                                                                                                                                                      No it's because we are getting paid too much.

                                                                                                                                                                      • slt2021 21 hours ago

                                                                                                                                                                        this one, once money trickled in, tech attracted people who are doing it for the money only, not for the love of tech.

                                                                                                                                                                        big tech sort of replaced wall street as main career choice for some people and naturally attracted "wallstreet bros" type into the tech, who are now known as "tech bros"

                                                                                                                                                                        • npteljes 9 hours ago

                                                                                                                                                                          Or, one could argue that the influx of money and the ever-increasing hardware capability enabled saner, more human languages. Human both in design, as in, easier to learn, more accommodating to human mental models, and human in a way that they account more for human fallacies. Something that old languages, and lower levels of abstractions cannot do, because it's expensive to double-check, or to defend against the human.

                                                                                                                                                                      • agentultra 4 hours ago

                                                                                                                                                                        I enjoyed how witty and charming the community was back in the 90s when I was into Perl.

                                                                                                                                                                        I had a similar path to Perl as a lot of people here. I was making games and into C when I learned about Linux from a friend. From there I heard about Perl and started using it to automate making my websites… those halcyon days before someone started calling them “web logs,” and later, “blogs,” etc.

                                                                                                                                                                        Text munching and slinging around files was much easier in Perl than it was in C and I became a big fan.

                                                                                                                                                                        The community was awesome. And the books were great.

                                                                                                                                                                        I feel like Perl embodied that hipster-Socialist Bazaar style moment in programming/tech.

                                                                                                                                                                        • boothby 3 hours ago

                                                                                                                                                                          Kids these days aren't learning Malbolge as their first language and it really shows.

                                                                                                                                                                          I loved Basic, then VisualBasic, then C, and then Perl... and after Perl, I've never really found it challenging to learn a new language. After almost a year of working on some cgi script (gossamer threads, I think?) I had this alarming realization that I did not understand the context of a block of code I seemed to spend most of my time editing. It was a multi-page regular expression. I was (and am still) pretty naive to how the language is implemented or even parsed, and I find it most interesting how we can write in languages with the barest understanding of their underlying details. I'm at that point with a lisp, occasionally catching glimpses below the surface, but now with decades of diving deep and in other languages. Sometimes I think it might be fun to return to Perl, but when I read modern Perl, it seems to bear such little resemblance to the code of 25 years ago.

                                                                                                                                                                          • ddellacosta 21 hours ago

                                                                                                                                                                            I can't read this article due to the paywall, but here's my lukewarm take based on the title at least: "nobody" codes in Perl any more because the language lost a lot of mindshare in the transition from Perl 5 to Perl 6, a.k.a. Raku. And regardless it's always been a fairly idiosyncratic language in a lot of ways. Stuff like Ruby (which inherits DNA from Perl along with Lisp and Smalltalk), PHP (also takes some notes from Perl, perhaps more superficially), and Python ate a lot of its lunch.

                                                                                                                                                                            It was the first language I wrote professionally and I always thought it was a lot of fun, but if I want to be humbled these days I reach for Haskell (like a lot of the Perl community it sounds like...).

                                                                                                                                                                            EDIT: okay I read the article, thanks to welpo for the archive link. Yeah this is kind of a nostalgic piece so I think my original comment is still relevant. I do like Perl still, I will always have a spot in my heart for it. I appreciate especially how seriously Larry Wall tried to think about approaching things vis-a-vis linguistics even if I don't necessarily think that's the best approach for a language used by an engineering team these days.

                                                                                                                                                                            I hope it sticks around in any case. It is truly unique.

                                                                                                                                                                            • stouset 21 hours ago

                                                                                                                                                                              I agree it was a combination of Raku and Ruby. As far as I'm concerned, Ruby deprecates Perl 5. It fills the same niche while avoiding a lot of the absolutely crazier parts of Perl (no shade; Perl was designed in a far different time and place). If you know Ruby, there is essentially zero reason to learn Perl. I have fond memories of the language, it was the first one I wrote professionally, but never again.

                                                                                                                                                                              Raku being in such an indeterminate state for so long was an eternity for it to lose mindshare to Ruby.

                                                                                                                                                                              • ddellacosta 21 hours ago

                                                                                                                                                                                > If you know Ruby, there is essentially zero reason to learn Perl.

                                                                                                                                                                                I don't think I ever thought about it but I think I have implicitly taken this to heart since I last was using Perl seriously. Almost every engineering org I've worked for in the last decade has had Ruby as a part of its stack for e.g. scripting or lambdas and it's what I reach for when I need to script something. And I've done Rails work in a few orgs too, which has few parallels in its niche even without considering Perl.

                                                                                                                                                                                Although I suspect for most people Python is where they land if we're just talking about scripting or hacking something together...or anything (I hate it but it is what it is lol).

                                                                                                                                                                                • citrin_ru 20 hours ago

                                                                                                                                                                                  > If you know Ruby, there is essentially zero reason to learn Perl

                                                                                                                                                                                  When I still used Perl (10y ago) Ruby was notably slower on many tasks. Ruby probably the slowest among popular script languages.

                                                                                                                                                                                  • stouset 19 hours ago

                                                                                                                                                                                    Bordering on zero percent of projects too performance sensitive to be written in Ruby should be written in Perl instead.

                                                                                                                                                                                • calmbonsai 21 hours ago

                                                                                                                                                                                  I used Perl extensively for small-network (~25 boxen) sysadmin and local/personal tooling, but never in cluster/multi-node deployed production. It gave too much freedom for expression making it difficult to "team-scale".

                                                                                                                                                                                  I stopped using it circa 2000 for no real reason other than Python was easier for teams to adopt and common modules became well-maintained enough where CPAN was no longer a competitive advantage. It also helped that Guido lived and worked a few minutes north in Reston, VA back then.

                                                                                                                                                                                  That said, I still "think" in Perl regex to this very day. ;)

                                                                                                                                                                                  • ddellacosta 21 hours ago

                                                                                                                                                                                    > That said, I still "think" in Perl regex to this very day. ;)

                                                                                                                                                                                    Yeah good point, if there's one thing from Perl that will live far longer than the language itself it's PCREs. I can't thank my experience with the language enough for my facility in crafting regexps.

                                                                                                                                                                                    • xarope 12 hours ago

                                                                                                                                                                                      Agreed, Perl introduced me to REGEX and hashes. To this day, whenever I do any work with data, I tend to think in terms of REGEX first rather than convoluted string manipulation.

                                                                                                                                                                                    • graemep 21 hours ago

                                                                                                                                                                                      Like many paywalls it goes away if you turn off JS.

                                                                                                                                                                                    • antithesizer an hour ago

                                                                                                                                                                                      Discovering Perl made me feel like a god.

                                                                                                                                                                                      • elashri 21 hours ago

                                                                                                                                                                                        I am not old enough to have learned perl but not young enough to not know some perl and its problems.

                                                                                                                                                                                        But the article or at least the title would be much more suitable if perl is replaced by "CUDA". You can't be working with that and be arrogant, because even self centric people would suffer enough pain not to change. And if perl makes you feel it is made by humans. Then "CUDA" sure would feel like something that came straight from the hell.

                                                                                                                                                                                        Note: I understand that the article is more about talking about perl and remind people that it existed and was famous language one day. But I couldn't resist the temptation of the title.

                                                                                                                                                                                        • shermantanktop 21 hours ago

                                                                                                                                                                                          Interesting - one of the most single-mindedly arrogant engineers I ever worked with was an absolute zealot about CUDA.

                                                                                                                                                                                          Could not stop talking about CUDA, and why everything else was terrible, and how nobody listened to him, and how that was because they couldn't handle the truth, and how he could solve everyone's problems if they would only let him, on and on. He didn't last that long at my company.

                                                                                                                                                                                          Maybe he was taking his CUDA pain and pushing it onto other people.

                                                                                                                                                                                        • drewcoo 21 hours ago

                                                                                                                                                                                          The three virtues of a Perl programmer are impatience, hubris, and laziness.

                                                                                                                                                                                          There's no humility in the list.

                                                                                                                                                                                          • dooglius 12 hours ago

                                                                                                                                                                                            For the downvoters: that's a quote from Larry Wall, not an insult.

                                                                                                                                                                                        • superkuh 13 hours ago

                                                                                                                                                                                          I write some new Perl/Gtk application a couple times a year. And I use it for automating basic things almost daily. I bet lots of people chose to write in perl for personal projects. It just isn't very visible.

                                                                                                                                                                                          But not that many. And that's why Perl is still Perl. Popularity brings change which means old code stops working.

                                                                                                                                                                                          Perl code from the year 2000 still works in a perl interpreter+libs today. And perl code written today still works on perl interpreter+libs from the year 2000. That incredible stability and reliability is what makes it great. Write something then use it 20 years later and everything just works anywhere you try to run it.

                                                                                                                                                                                          That's why I chose Perl.

                                                                                                                                                                                          • kwoff 21 hours ago

                                                                                                                                                                                            It's kinda ironic, since one of the three "virtues" of a Perl programmer is hubris, heh.

                                                                                                                                                                                            (re nobody codes in Perl: I still do professionally, and I'll probably never understand why it draws so much hate)

                                                                                                                                                                                            • johnisgood 11 hours ago

                                                                                                                                                                                              I write Perl, too, and I love it. I have comments, especially next to the regexes, but honestly, I think my code is readable and maintainable because I went back to it a year later and I still understand everything.

                                                                                                                                                                                            • niccl 21 hours ago

                                                                                                                                                                                              Hmm. and PERL is not one of the most popular languages these days. In contrast with Python and its

                                                                                                                                                                                                There should be one-- and preferably only one --obvious way to do it.
                                                                                                                                                                                              
                                                                                                                                                                                              It does not seem coincidence to me
                                                                                                                                                                                              • aynyc 21 hours ago

                                                                                                                                                                                                There is almost nothing in today’s Python world that follow that axiom.

                                                                                                                                                                                                There is a new package manager every year. Language features are introduced every major release.

                                                                                                                                                                                                • fch42 20 hours ago

                                                                                                                                                                                                  But there are 500 linters to help you with idio(to)matic python coding. Honi soit qui mal y pense ...

                                                                                                                                                                                                • SoftTalker 21 hours ago

                                                                                                                                                                                                  Yeah I think TIMTOWTDI ended up being a net negative. Of course with experience and learning the idioms (perl is very idiomatic) it's not so bad but it really adds to the cognitive load for a beginner.

                                                                                                                                                                                                  There is still a lot of perl around but I'd be a little surprised if any new projects would use it at least where it doesn't already have a big presence.

                                                                                                                                                                                                  • rossant 20 hours ago

                                                                                                                                                                                                    In case anyone asks: there is more than one way to do it.

                                                                                                                                                                                                  • mrweasel 5 hours ago

                                                                                                                                                                                                    Well, I mean there's frequently the obvious way to do something, then there's a large number of less obvious ways, then there's the obvious way of doing it if you're mostly programming using Pandas, or NumPy, and Python is more of an implementation detail.

                                                                                                                                                                                                    I agree with the intention of the quote, sadly it didn't work out like that.

                                                                                                                                                                                                    • drewcoo 21 hours ago

                                                                                                                                                                                                      Perl is not an acronym.

                                                                                                                                                                                                      • _kst_ 20 hours ago

                                                                                                                                                                                                        Not officially, but there are a couple of retronyms.

                                                                                                                                                                                                        Larry Wall originally wanted to call it "Pearl", but found there was already a language by that name, so he shortened it to "Perl".

                                                                                                                                                                                                        The name is sometimes expanded as "Practical Extraction and Report Language", or as "Pathologically Eclectic Rubbish Lister" (Larry Wall's own phrase, mentioned in the Perl man page).

                                                                                                                                                                                                        But yes, "Perl", not "PERL", is the correct name for the language.

                                                                                                                                                                                                        (Ada, which was named after a person, has had the same problem, though as far as I know there isn't even a retronym for Ada.)

                                                                                                                                                                                                    • Natsu 21 hours ago

                                                                                                                                                                                                      There are still a few of us Perl programmers around, though it's far less popular than it was a few decades ago.

                                                                                                                                                                                                    • Dove 3 hours ago

                                                                                                                                                                                                      I miss perl. I encountered it in school, in 1998, and fell head over heels in love. Used it professionally a lot longer than was probably justified, given the mores and availability of programmers. The Camel Book set my formative opinions on what software should be like, and I'll surely be a perl programmer at heart forever.

                                                                                                                                                                                                      I gave it up in 2020, perceiving that python had won. It was a sad day - working in python feels like typing while missing three fingers. I go to reach for an idiom and not only is it not there, I'm told the phantom limb syndrome is for everyone's good, including mine.

                                                                                                                                                                                                      I've never found the code of skilled perl programmers difficult to read. I think bad programmers will always write code that is difficult to work with, even in languages that are supposed to prevent it. The most miserable time I ever had understanding someone else's code came at the hands of a brilliant, overly clever, somewhat inexperienced python hacker. I will admit, though, that this feat of confusion required a prodigy, whereas perl makes it quite easy to shoot everyone in a thirty yard radius in the foot. Just the same, I've always thought the messiness of perl was a myth, a result of misuse, abuse, and inexperience. Well written perl conveys much at a glance where in visually cleaner languages, all shapes have the same outline.

                                                                                                                                                                                                      But it's also true that by the time I gave it up, I was already looking for a replacement. The language is bold and beautiful and opinionated, and in the fullness of time, some of those opinions proved to be wrong. The world moved forward and perl didn't, and I found myself wanting to do things with objects, and types, and tooling, and functions, and exceptions, that it just didn't do, or didn't do well. Some languages, like PHP and javascript, grew beyond their humble beginnings and bolted on the rigorous and increasingly mandatory machinery of the modern world. Perl didn't.

                                                                                                                                                                                                      So my leaving had two big factors: the language didn't grow up, and people didn't want to read my code.

                                                                                                                                                                                                      I'm still looking for a replacement. The serious contenders seem to be Go and Ruby, both of which I really like a lot. I dabble in Haskell and Lisp looking for pieces of what I've lost. I have negotiated an uneasy ceasefire with python and javascript out of professional obligation. We can work together, though admittedly neither one of us is entirely happy about it.

                                                                                                                                                                                                      Perl was a beautiful thing, a thing I appreciated like art and poetry. I'm glad to have been there for the years in which it flourished. But I also think the world has passed it by. Even looking past hacked in features, it had a more fundamental problem. The tug of war between standardization and expression is like the one between society and the individual. Neither side should ever really win, but perl favored expression more than we now think is wise. We didn't know it then. And the feeling was glorious. But in the decades since, we all - myself included - have decided the balance between those things is ... well we don't know exactly where it is, but we do know it involves less individual freedom than that. The language made a lot of gambles that turned out wrong, but that's the big one.

                                                                                                                                                                                                      I think lisp fell prey to that, too, by the way. So formless and expressive that by the time you got done writing your software, you'd essentially invented a language specific to it. Great, in the narrow scope of your project, language and domain fitting hand in glove. Not awesome if you need to hire help. Ads for people who speak Emacs Lisp or Autocad Lisp are telling. You can invent the most beautiful language in the world, but the fact that only three people speak it is surely a strong point against it.

                                                                                                                                                                                                      Perl is and was a beautiful thing. I miss it. I seek out its children when I can. I write jokes and references and eulogies where I can, tucking little utility functions stolen from perl into languages where they don't belong, places that never touched that unix heritage. Perl is humble enough to give you the space to do things your way, rather than its way, giving you permission to break all the rules and requesting that you use the freedom with wisdon and goodness and politeness. That sort of bold faith and generosity sparks in me a fierce love. I haven't found it anywhere else. I doubt I will, because as wonderful as it is, it's since been considered unwise. Programming is a social endeavor, and while a specialist language like GLSL can thrive in a little niche, a glue language spoken by only a few people isn't a glue language at all - it's another arcane system that needs to be glued. No, python won. Perhaps it even deserved to.

                                                                                                                                                                                                      So for me, perl is dead... but also long live perl.

                                                                                                                                                                                                      • kkylin 12 hours ago
                                                                                                                                                                                                        • karel-3d 11 hours ago

                                                                                                                                                                                                          Perl sigils are horrible; perl magical variables are horrible, perl lack of sane object and argument passing is horrible. (Moose was improvement but slow, if I remember well.) It's a language of cludges on top of other cludges.

                                                                                                                                                                                                          I guess it became popular because it existed and there was nothing better (nobody will write in awk if not pressed to).

                                                                                                                                                                                                          We don't need badly designed tools to stay humble. There is enough cognitive load from all the bad programmers (and now LLMs spewing slop), no need to add another nonsense.

                                                                                                                                                                                                          I admit though that writing perl makes you feel "clever" - "huh that's a funny shortcut I didn't know! Writing $\<>^^ will give me name of last used file on blue moon on thursday!" but... uh.

                                                                                                                                                                                                          • 18172828286177 21 hours ago

                                                                                                                                                                                                            > If I had to choose a language that is furthest from Perl, it might be Lisp.

                                                                                                                                                                                                            Rust

                                                                                                                                                                                                            • layer8 7 hours ago

                                                                                                                                                                                                              They are similarly punctuation-heavy, and both use C-derived syntax, and both are imperative languages, so I would disagree.

                                                                                                                                                                                                              • johnisgood 11 hours ago

                                                                                                                                                                                                                He said furthest. That might be Lisp or Haskell or anything along these lines.

                                                                                                                                                                                                              • test1072 21 hours ago

                                                                                                                                                                                                                Paywall