- 39
- 53
I'm working on a project in Python and there's a very obvious, almost textbook, spot to throw in some concurrency. I'm allergic to reading documentation and most of my code comes from modifying stackoverflow snippets so I perhaps naively googled "python threading" and implemented that. Imagine my surprise when I got literally no performance gain. So I looked into it and it turns out threads in Python are just fake threads, the entire program still runs in a single thread. You get all the overhead of concurrency with none of the benefits.
So I switched over to the multiprocessing library, which thankfully was pretty painless since it works almost identically to the threads library except with, you know, actual concurrency. That started out ok but I ran into trouble trying to return complex objects from the spawned processes. You can return simple data types pretty easily in a thread safe way, and even objects composed of simple data types, but trying to return an object that contains another object simply doesn't work. So once again I looked into it more and it turns out I have to specifically use a SyncManager if I want to return complex objects. So once again I implement that and it finally fricking works after hours of mucking around in the shit.
Why are there like 30 different ways to do concurrency in Python, with most of them sucking butt or not working at all? I've done concurrency in lots of other languages and they're all very straightforward. Even fricking C++ makes it easy to implement.
- 1
- 12
- 15
- 26
Wow. This is apparently what was supposed to be a STATIC FIRE TEST today of a Tianlong-3 first stage by China's Space Pioneer. That's catastrophic, not static. Firm was targeting an orbital launch in the coming months. https://t.co/BY9MgJeE7A pic.twitter.com/L6ronwLW1N
— Andrew Jones (@AJ_FI) June 30, 2024
-
whyareyou
: thats what i get for not checking the username
- Cusek : I'm not clicking on that
- JohnDevereaux : UH-UHHH neighbor I ain't fallin for that shit no more
- DickButtKiss : Ignore the username, this link is actually legit
-
Sner
: locking house holes was a MISTAKE
- 14
- 27
Unsuprisingly furries showed complete and utter domination, and none of the competition even came close Another !furries dubski
30k in MBUX has been awarded to @Sner the GOAT (even though he's an eagle).
Previous thread : https://rdrama.net/post/279099/best-gay-art-voting-the-marseybeach
Shouldn't have split it in two but that was a hangover from an earlier idea
- 21
- 50
- 24
- 30
1. They're stinky
2. They can't walk straight
3. They talk shit
4. They're broke from buying booze all the time
5. They can't handle responsibilities
6. They're loud
7. They're male feminists
8. They're a burden on our healthcare system
9. They drive drunk
and kill people
10. They act stupid and reckless
- 42
- -4
Ideas? I say we doxx him and then show up at his place with cacti to repeatedly shove up his butt
- Aevann : SHUT IT DOWN
- BraveShill : Truer words have never been spoken
- DickButtKiss : This was obviously made by an agenda-posting buttburt libtard
- 190
- 183
Link to the tool
https://glif.app/@fab1an/glifs/clxtc53mi0000ghv10g6irjqj
Prompt was "The average rDrama.net user"
- 25
- 25
- 75
- 68