People get mad when things make them feel bad. They don’t want to fix anything they just don’t want to feel bad.
- 0 Posts
- 408 Comments
On the one hand, omnipresent surveillance is bad and ripe for abuse.
On the other, I feel like the haphazard and selective enforcement of traffic laws by police officers is also really bad. Cops can selectively enforce laws so poor people or black people or whatever out-group suffers more. A machine should be impartial.
On the last hand, no traffic enforcement is probably going to get people killed. So that’s not desirable.
Also, fines are problematic. Fines should probably scale with wealth, but also it shouldn’t be a revenue source because that’s a perverse incentive.
I’ve been pushing to add some basic checks on PR, and people are reluctant. There’s one repo that I’m code owner on so I spent the like 15 minutes to apply a code formatter and add a GitHub action to check. But on the main repo people are dragging their heels. I’m like just pick ruff or black and do it. It’s going to take like 10 minutes. I’m not asking for us to go crazy and add automated tests right now, but can we at least get something to verify the python code is syntactically correct?
The other day something went through code review until I looked at it and saw there was an extra
(, and that shit wouldn’t even run. I’m like please please add an automated check. I’ll do it. Please.I think a lot of people just aren’t familiar with how other places do software. This is the same place that was ssh’ing into prod and making changes right on the machine until like this month.
I’m kind of bummed no one at my job really does code reviews seriously. I don’t really get any feedback, so it’s hard to improve.
That’s also probably why the older code is an idiosyncratic mess of mutations and "oh yeah you need this config file that’s not in source control " and “oh sorry I guess I hard coded that file path, huh?”
I also didn’t get it. Thank you folks for explaining it!
jjjalljs@ttrpg.networkto
Programmer Humor@programming.dev•What are some of the worst code you have seen in a production environment?
29·12 days agoThere was a website where users could request something or other, like a PDF report. Users had a limited number of tokens per month.
The client would make a call to the backend and say how many tokens it was spending. The backend would then update their total, make the PDF, and send it.
Except this is stupid. First of all, if you told it you were spending -1 tokens, it would happily accept this and give you a free token along with your report.
Second of all, why is the client sending that at all? The client should just ask and the backend should figure out if they have enough credit or not.
Yeah, but I guess megacorps like Warner Brothers are even more obscene than elder gods.
jjjalljs@ttrpg.networkto
Programming@programming.dev•What's the best way to monitor an API for breaking changes?
2·18 days agoYeah I would use python and pytest, probably.
You need to decide what you expect to be a passing case. Known keys are all there? All values in acceptable range? Do you have anything where you know exactly what the response should be?
How many endpoints are there?
One of the shadow of Mordor games made sexy shelob and it was bad.
jjjalljs@ttrpg.networkto
Today I Learned@lemmy.world•TIL: There are 27.4 Empty Homes for Each Homeless Person in the U.SEnglish
2·19 days agoA lot of those places suck and they’re not going to turn into vibrant cultural centers with social services quickly.
Only if you’re still browsing fridge websites!
Lowering indent levels is nice in functions. Early returns mean you don’t have to think as much. “If it got here, I know foo isn’t null because it already would have returned”.
Yeah some comments are not useful
# returns the value as a string return str(user.id)Some comments are
# returns the user id as a string because ZenDesk's API throws errors if it gets a number. # See ticket RA-1037 # See ZenDesk docs: https://etc/ return str(user.id)
I feel like contextual ads, where you serve ads based on the surrounding content instead of who the individual user is would be about as effective and tremendously less expensive, complicated, and invasive.
Run football ads on football websites. Run music ads on music websites. That’s how it works in TV, radio, and so on and has for years.
Just remove all violent people first
Communication aims at information exchange,
Metadata is data. Skipping small talk is exchanging less information.
One of my jobs went to microservices. Not really sure why. They had daily active users in the thousands, maybe. But it meant we spent a lot of time on inter-service communication, plus local development and testing got a lot more complicated.
But before that, it was a single API written in Go by an intern, so maybe it was an improvement.
It’s wild to me how some places I’ve worked are like locked down, all the infrastructure is in terraform or whatever and can be deployed immediately… and other places are like “ssh into prod with the credentials from confluence, edit the config in vim, and paste the new code into a new file”
jjjalljs@ttrpg.networkto
memes@lemmy.world•I literally describe breathtakingly good pizza as "cartoon pizza"
9·1 month agoOne time in a game of DND the players were exploring a strange cave system, and found a strange thick goo collecting in a pool. Players being players, one of them decided to eat some.
It was, in my notes, some sort of celestial honey made by these extra planar insects that were causing some of the region’s problems. It was supposed to taste amazing, but with some drawbacks. I started to blank when trying to describe how good it was, and the phrase that came out was “it’s like… It’s like … it’s like seven pizzas!”
The player eating it, his eyes lit up and was like “AMAZING”
The other players were like “wat”
I think that adequately captured how delicious it is but also maybe you shouldn’t be eating it.

That’s how I read it as well. People who say there’s no ethical consumption, and then act like all wrongs are equally wrong so they might as well do the worst thing.