• ramjambamalam@lemmy.ca
    link
    fedilink
    arrow-up
    9
    ·
    edit-2
    1 month ago
    • Push directly to master, not main
    • No command line args, just change the global const and recompile
    • No env vars either
    • Port numbers only go up to 5280, the number of feet in a mile
    • All auth is just a password; tokens are minority developers, not auth, and usernames are identity politics
    • No hashes – it’s the gateway drug to fentanyl
    • No imports. INTERNAL DEVELOPERS FIRST
    • Exceptions are now illegal and therefore won’t occur, so no need to check for them
    • SOAP/XML APIs only
    • No support for external machines. If it’s good enough for my machine, it’s good enough for yours.
    • Rikudou_Sage@lemmings.world
      link
      fedilink
      arrow-up
      1
      ·
      1 month ago

      Exceptions are now illegal and therefore won’t occur, so no need to check for them

      Ah, I see you’ve met C++ developers.

        • qaz@lemmy.world
          link
          fedilink
          English
          arrow-up
          1
          ·
          1 month ago

          It was kind of pointless, but at least it made software work with custom default branches.

        • chonglibloodsport@lemmy.world
          link
          fedilink
          arrow-up
          1
          ·
          1 month ago

          Yes exactly. It’s a reference to the recording industry’s practice of calling the final version of an album the “master” which gets sent for duplication.

          • Zink@programming.dev
            link
            fedilink
            arrow-up
            0
            ·
            1 month ago

            In alignment with this, we should not replace the master branch with the main branch, we should replace it with the gold branch.

            Every time a PR gets approval and it’s time to merge, I could declare that the code has “gone gold” and I am not doing that right now!

            • ramjambamalam@lemmy.ca
              link
              fedilink
              arrow-up
              3
              ·
              1 month ago

              Merged -> gone gold

              Deployed -> gone platinum

              Gone a week without crashing production -> triple platinum

        • Maggoty@lemmy.world
          link
          fedilink
          arrow-up
          0
          ·
          1 month ago

          But why even? There’s no risk to changing it and some risk to keeping it. That’s the reason for the push to change it. Keeping something just because it’s tradition isn’t a good idea outside ceremonies.

          • weker01@sh.itjust.works
            link
            fedilink
            arrow-up
            0
            ·
            edit-2
            1 month ago

            There is definitely a risk in changing it. Many automation systems that assume there is a master branch needed to be changed. Something that’s trivial yes but changing a perfectly running system is always a potential risk.

            Also stuff like tutorials and documentation become outdated.

            • Maggoty@lemmy.world
              link
              fedilink
              arrow-up
              0
              ·
              1 month ago

              If they can’t change what’s essentially a variable name without issues then should they be doing the job?

              • MadhuGururajan@programming.dev
                link
                fedilink
                English
                arrow-up
                1
                ·
                27 days ago

                pray tell me how would you change the name in every script of an automation system that refers to master? Remember, you have to justify the time and cost to your manager or director!

        • tyler@programming.dev
          link
          fedilink
          arrow-up
          0
          arrow-down
          1
          ·
          1 month ago

          Yeah agreed. Just another piece of white devs acting like they knew better for everyone.

  • MTK@lemmy.world
    link
    fedilink
    arrow-up
    2
    ·
    1 month ago

    Error handling should only be with “if”

    Variable names must be generic and similar to each-other

    Debugging is only done with prints

    Version numbers must be incoherent, hard to order correctly, contain letters and jump in ways that don’t align with the updates done.

      • xmunk@sh.itjust.works
        link
        fedilink
        arrow-up
        3
        ·
        1 month ago

        Hey now, you know that according to the Bible the biggest number is a million. Anything larger than that including infinity is some of that “woke shit”.

        Your array will be 999,999, 999,998, 999,997 …

        • pelya@lemmy.world
          link
          fedilink
          arrow-up
          3
          ·
          1 month ago

          In Lua all arrays are just dictionaries with integer keys, a[0] will work just fine. It’s just that all built-in functions will expect arrays that start with index 1.

          • my_hat_stinks@programming.dev
            link
            fedilink
            arrow-up
            1
            ·
            1 month ago

            That’s slightly misleading, I think. There are no arrays in Lua, every Lua data structure is a table (sometimes pretending to be something else) and you can have anything as a key as long as it’s not nil. There’s also no integers, Lua only has a single number type which is floating point. This is perfectly valid:

            local tbl = {}
            local f = function() error(":(") end
            
            tbl[tbl] = tbl
            tbl[f] = tbl
            tbl["tbl"] = tbl
            
            print(tbl)
            -- table: 0x557a907f0f40
            print(tbl[tbl], tbl[f], tbl["tbl"])
            -- table: 0x557a907f0f40	table: 0x557a907f0f40	table: 0x557a907f0f40
            
            for key,value in pairs(tbl) do
              print(key, "=", value)
            end
            -- tbl	=	table: 0x557a907f0f40
            -- function: 0x557a907edff0	=	table: 0x557a907f0f40
            -- table: 0x557a907f0f40	=	table: 0x557a907f0f40
            
            print(type(1), type(-0.5), type(math.pi), type(math.maxinteger))
            -- number	number	number	number
            
          • frezik@midwest.social
            link
            fedilink
            arrow-up
            1
            ·
            1 month ago

            PHP did that same thing. It was a big problem when algorithmic complexity attacks were discovered. It took PHP years to integrate an effective solution that didn’t break everything.

      • UndercoverUlrikHD@programming.dev
        link
        fedilink
        arrow-up
        0
        ·
        1 month ago

        Writing Lua code that also interacts with C code that uses 0 indexing is an awful experience. Annoys me to this day even though haven’t used it for 2 years

    • dan@upvote.au
      link
      fedilink
      arrow-up
      1
      ·
      1 month ago

      Visual Basic used to let you choose if you wanted to start arrays at 0 or 1. It was an app-wide setting, so that was fun.

    • lefixxx@lemmy.world
      link
      fedilink
      arrow-up
      0
      ·
      1 month ago

      How is arrays starting at 1 still a controversial take. Arrays should start at 1 and offsets at 0.

  • JackbyDev@programming.dev
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 month ago

    Arrays not starting at 1 bother me. I think the entrenched 0-based index is more important than any major push to use 1 instead, but if I could go back in time and change it I would.

    • Overshoot2648@lemm.ee
      link
      fedilink
      arrow-up
      0
      ·
      1 month ago

      It really doesn’t make sense to start at 1 as the value is really the distance from the start and would screw up other parts of indexing and counters.

  • kamen@lemmy.world
    link
    fedilink
    arrow-up
    1
    ·
    1 month ago

    Implying the orange fella has any say in programming language design and general tech conventions