• _____@lemm.ee
    link
    fedilink
    English
    arrow-up
    8
    ·
    2 days ago

    I have nothing to add except: man’s really wrote like 7 classes to just have 1 function each

      • _____@lemm.ee
        link
        fedilink
        English
        arrow-up
        3
        ·
        2 days ago

        Honestly, if they want to go full enterprise at least use the javabeanfactoryfactoryfactory pattern

    • Ephera@lemmy.ml
      link
      fedilink
      English
      arrow-up
      1
      ·
      2 days ago

      Yeah, I’m really wondering why they thought this was a good idea. My best guess is that they want to keep everything within one file, since it makes the script easier to deal with. But when automation actually starts being implemented, they want the functions for each task to be grouped (and I believe, Python doesn’t support inline modules), so they abuse classes for that…?
      Well, and I guess, it allows them to have pseudo-constants within each task, which don’t need to be explicitly passed around between functions.

      But yeah, really not a fan of needing this much boilerplate to start out with. In my opinion, the activation energy required to use this pattern instead of slapping down documentation needs to be as minimal as possible, otherwise folks will slap down documentation instead.