BeatTakeshi@lemmy.world to Programmer Humor@lemmy.ml · 1 day agoWhen you run out of Claude tokenslemmy.mlimagemessage-square40linkfedilinkarrow-up1461arrow-down113file-text
arrow-up1448arrow-down1imageWhen you run out of Claude tokenslemmy.mlBeatTakeshi@lemmy.world to Programmer Humor@lemmy.ml · 1 day agomessage-square40linkfedilinkfile-text
minus-squareSonotsugipaa@lemmy.dbzer0.comlinkfedilinkEnglisharrow-up14·1 day agoTIL that thread safety is a thing in Python
minus-squareTrioxin@lemmygrad.mllinkfedilinkarrow-up5·1 day agoWell, yes… While the GIL restricts execution to only a single thread, CPython makes threads take turns on it without regard for your code - so a thread can give the lock up to another in the middle of a critical section.
TIL that thread safety is a thing in Python
Well, yes… While the GIL restricts execution to only a single thread, CPython makes threads take turns on it without regard for your code - so a thread can give the lock up to another in the middle of a critical section.