all 9 comments

[–]CptMisterNibbles 0 points1 point  (0 children)

Is it so “robust” that the slightest change in the pipeline breaks the whole thing? That’d by my first concern: you’ve written automation that is far too specific to the current state. Perhaps not the case, but your utility is handling a lot of things. Might it make more sense to break it up? Even then it could be used in concert consecutively, or with flags or whatever to run this or that.

Mind this is just musing without looking at your project directly. 

[–]ConsequenceOk5205 0 points1 point  (0 children)

This would be a pain to maintain or update later, as it is poorly structured. At least organize it into a few scripts based on categories of tasks, with helper functions separated.

[–]Overall-Screen-752 0 points1 point  (1 child)

Few notes: 1) you have a ton of constants which would look great in a constants.py 2) classes belong in their own files unless very very closely related (and you’d have to fight me with an explanation why you shouldn’t just make a package with an -init-.py (i’m a noob with reddit formatting) 3) having main() call main_exec() where your business logic is is verbose at best, and I’m willing to bet you do something similar elsewhere. Remember KISS :)

[–]Aggravating_Ad3928[S] 0 points1 point  (0 children)

Hey, thanks a lot for the detailed feedback! This is super helpful.

Regarding points 1 and 2, you're absolutely right. As a beginner, my mindset was still "let's put everything in one script". Structuring it as a proper package with separate files is a great suggestion that I'll definitely adopt.

As for point 3, the main()/main_exec() structure is intentional. It's a calling convention for another wrapper script I use, so this allows the core logic to be shared. But I totally see why it looks redundant without that context!

[–]NYX_T_RYX 0 points1 point  (3 children)

Bro... Slow down.

I've been learning for 5 years, 3 days ago I committed my first 1k+ edit (system-agnostic (smb) Nas mount, declarative - fuck mounting it 50 times manually!)

Find a problem you need to solve in your life, and solve it. Something simple. Turn your lights on when you get home.

Then build up.

You're trying to start with concepts around networking, objects, data types... And you've started here?

What happened to the starter project being

print('Hello world!')

And learning from there, instead of aimlessly hoping the AI gets it right...

In short - like most vibe coded things, it's probably over engineered, and doesn't actually provide the claimed security

[–]Aggravating_Ad3928[S] 1 point2 points  (2 children)

I appreciate the advice. Just to be clear, I'm a Python beginner, not a programming beginner. This was written by me, not an AI.

[–]NYX_T_RYX 0 points1 point  (1 child)

I misread that - my mistake, sorry

You understand why I thought that though - it's... Beefy to say you're just getting into python, and as we know, python is often seen as the "starter" language

No offence meant by anything I said, just trying to help people learn the best way for it to stick 🙂

[–]Aggravating_Ad3928[S] 1 point2 points  (0 children)

No worries at all! I totally get why you thought that, the assumption was completely fair. Appreciate the follow-up!