this post was submitted on 06 Feb 2024
110 points (94.4% liked)

Programming

17270 readers
39 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities [email protected]



founded 1 year ago
MODERATORS
(page 2) 50 comments
sorted by: hot top controversial new old
[–] [email protected] 10 points 9 months ago* (last edited 9 months ago) (2 children)

Myth: You are lazy.

Truth: It's highly probable you are neurodivergent.

While, accurate numbers are not available, I have seen people estimating that 20% of people working in FAANG are neurodivergent. If coding comes naturally to you but the laundry is your mortal enemy, it's worth learning about ADHD/ASD and other common disorders. Being a coder can be a sign, the immediate feedback helps a bunch of us, or as Russel Barkely says "when you solve a problem on a paper, NOTHING HAPPENS".

Edit: Rephrase.

load more comments (2 replies)
[–] [email protected] 9 points 9 months ago (2 children)

That “just changing a word” is easy and quick. A codebase is an iceberg. Management only really typically understands the surface, but there is a disproportionate amount of ice under the water.

I had to change all instances of a label from a word to an abbreviation. Because we don’t have i18n set up in the app, it ended up affecting 55 different files. I did my best to consolidate into everything calling a common function, but it’s far from perfect. 55 files changed because management said “oh this word here should be shorter”.

load more comments (2 replies)
[–] [email protected] 8 points 9 months ago

It's not magic

[–] [email protected] 5 points 9 months ago (3 children)

That Python is the most readable language. Merely forcing an indentation style is only part of the issue. Python programmers have a tendency to write a bunch of named parameters all on one line, and it's a mess.

Even the automated documentation can't make it right. What the hell is this shit?

class werkzeug.test.EnvironBuilder(path='/', base_url=None, query_string=None, method='GET', input_stream=None, content_type=None, content_length=None, errors_stream=None, multithread=False, multiprocess=False, run_once=False, headers=None, data=None, environ_base=None, environ_overrides=None, mimetype=None, json=None, auth=None)

This is not enlightening. It might as well go on the shelf next to the worst regex you've ever seen. The automated doc generator needs to break these up to put one arg on each line, or just omit it altogether and let the detailed docs handle it.

It's not just the doc generator, either. I see this kind of style all the time in Python code. It's unreadable and it also makes it harder to figure out diffs when a parameter in the middle is changed (though it's helped by color coding for pull requests on GitHub and the like).

It's almost like the language attracted a bunch of people who thought indentation was the only thing you needed to make readable code. No further thought put into it.

load more comments (3 replies)
load more comments
view more: ‹ prev next ›