• oce 🐆
    link
    fedilink
    English
    arrow-up
    7
    ·
    9 months ago

    Python forcing end of line and tabs kinda does. Add Black auto-formatter and it’s pretty good.

    • frezik@midwest.social
      link
      fedilink
      English
      arrow-up
      1
      ·
      9 months ago

      I’ve seen too many Python devs write out complex statements all on one crammed up line. Including some that are in the main docs.

      Enforced whitespace is just one aspect of readable code. There are many others, and Python is no better at enforcing those than any other language.

      • oce 🐆
        link
        fedilink
        English
        arrow-up
        2
        ·
        9 months ago

        That would probably make very long lines and black would automatically add returns to line with proper indentations. But it has a a limit for sure. If you chain many list comprehensions it’s going to be a mess.