It is SO STUPID that spaces are widely preferred for indentation in code.

For the past, I don’t know, two hours I’ve been trying to fix YAML formatting issues that could have been fixed without any human intervention if only tabs were used. (It’s a big file, hence the duration.) (I know YAML doesn’t support tabs. That’s kind of my point.)

I even reluctantly asked Gemini (forced upon me by work; I was hoping it would change my mind in this case) why anyone would prefer spaces. It said the same irrelevant thing most people say: because some tools don’t support tabs properly.

Know what that sounds like to me? A problem with the fucking tool.

I don’t know if this is the right place to post this, but I can’t think of a better option.

  • BCsven@lemmy.ca
    link
    fedilink
    arrow-up
    17
    ·
    9 days ago

    We have a 40+ year old software (still developed, but some stuff never changed). They have the software read tables from space separated files. They trouble is each line has to line up with columns above it, so if you have a long string in one row, you have to go to every single line and space them with empty space to all line up the same.

    To make it even worse it was based on 80 character max, so if your column headers are more than 80, you create a second line with more column headers. So row 1 is your columns, row 2 is your next set of columns. Row 3 are spaced entries to line up with row 1. Row 4 are spaced entries to line up with row 2.

    And word wrap dosnt work because column rows have a CR after them.

    Its a freaking nightmare. This is why tabs are better

        • farmgineer@nord.pub
          link
          fedilink
          English
          arrow-up
          9
          ·
          9 days ago

          Japan and IT have an … Interesting relationship. If you can code, looking at parsing libraries can be interesting. There are all kinds of csv-ish abominations here. Multiple header rows, different headers if a line is empty, etc.

    • rektdeckard@lemmy.world
      link
      fedilink
      arrow-up
      4
      ·
      9 days ago

      That sounds like a simple problem that could safely be fixed in a day or days depending on the size of the data set, with a high degree of confidence.

      • BCsven@lemmy.ca
        link
        fedilink
        arrow-up
        3
        ·
        9 days ago

        Unfortunately its tied into the code and appa that compile those tables. And they need to support legacy customers who’ve built on top of that system. The software still opens files from that era to support aerospace customers who have a database of parts from that era.

        • thevoidzero@lemmy.world
          link
          fedilink
          arrow-up
          2
          ·
          9 days ago

          Why can’t you make it work with another format, and use a flag for legacy format for those clients. Then you don’t have to deal with it as much

          • BCsven@lemmy.ca
            link
            fedilink
            arrow-up
            1
            ·
            9 days ago

            I wish we could. I had hoped they’d move to CSV at least. Newer parts of the software support excel files.

            I assume Its feeding into a legacy codebase that they obviously don’t want to touch because it works and supports auto and aerospace across the globe. And many places still use data they generated in the 70s.

            The whole thing is terrible to work with, thankfully AI is great at converting simple formating to convoluted bullshit formatting.