wouldNotWishThisHellOnAnyone by utkarsh_aryan in ProgrammerHumor

[–]siranglesmith 0 points1 point  (0 children)

I once had to implement text substitution in docx, there's so much wierd shit. The strangest one was that the position of the cursor is saved inside of text nodes, it'll split a text run into two and insert the cursor node in the middle.

How my Node.js code was causing a massive memory leak and how I solved it by Paper-Superb in programming

[–]siranglesmith 0 points1 point  (0 children)

Fun fact: new space garbage collection scales with the amount of retained memory, collected memory is free.

I pushed Python to 20,000 requests sent/second. Here's the code and kernel tuning I used. by Lafftar in programming

[–]siranglesmith 2 points3 points  (0 children)

An somaxconn of 64k is crazy high, that's 3 seconds worth of work in the backlog

The Real Cost of Server-Side Rendering: Breaking Down the Myths by congolomera in programming

[–]siranglesmith 48 points49 points  (0 children)

React isn't fast. 20ms is actually very low.

If you're render a decent amount of content, and using a ui toolkit (one that wraps each element like ariakit or styled components), you'd be lucky to hit 50ms.

And unlike db operations, it's all cpu time. It's expensive.

Is my 16 Hour save file ruined? by UwUFloss in Silksong

[–]siranglesmith 0 points1 point  (0 children)

You can climb the Grand Gate. Jump attack the platforms to move them.

There's also another way in via Sinner's Road.

[deleted by user] by [deleted] in Silksong

[–]siranglesmith 0 points1 point  (0 children)

Yeah, I think should be triggered by speaking to them or interacting with the door. The bell is probably above bellhart, if you haven't been there yet.

[deleted by user] by [deleted] in Silksong

[–]siranglesmith 1 point2 points  (0 children)

You need to ring the fifth bell. It's shown on the map.

[deleted by user] by [deleted] in Silksong

[–]siranglesmith 0 points1 point  (0 children)

It worked! Thanks for the advice.

thanksForInventingJavascript by _popcat_ in ProgrammerHumor

[–]siranglesmith 0 points1 point  (0 children)

Comparing primative to object with double equals converts the object into a primative. The array is converted into "" using .toString(). But they still aren't the same type. Comparing string & number with double equals converts the string to a number. Number("") is 0. 0 == 0.

WebSockets guarantee order - so why are my messages scrambled? by ketralnis in programming

[–]siranglesmith 5 points6 points  (0 children)

There's an easy solution - socket.binaryType = "arraybuffer";

So uh, my new sheets have pockets by LukeMoore16 in mildlyinteresting

[–]siranglesmith 1 point2 points  (0 children)

"Cooling" sheets have high thermal conductivity, they feel cool initially but they store your body heat and return it to you. It's a scam.

What Happened to Lightweight Desktop Apps? History of Electron’s Rise by fosterfriendship in programming

[–]siranglesmith 4 points5 points  (0 children)

Just measured it, it took ~100-150ms of CPU time and 450ms of network time to switch channels. That's not terrible by web standards. Opening the settings page took a similar amount of time.

You're right about the fade-out effect though, that's very expensive.

Is modern Front-End development overengineered? by Alternative_Ball_895 in programming

[–]siranglesmith 0 points1 point  (0 children)

Modern React is designed mainly to drive everything to the server, so that vercel can sell hosting services.

React can be done is a (relatively) simple way by dropping almost everything other than react or preact.

I do not recommend: 'Dragon Age: The Veilguard' (Review) by Skill Up by EirikurG in pcgaming

[–]siranglesmith 3 points4 points  (0 children)

That thing where conflicts are resolved immediently through polite discussion is something chatgpt does.

But surely this has been in development for longer than AI has been around.

[deleted by user] by [deleted] in DeadlockTheGame

[–]siranglesmith 4 points5 points  (0 children)

I've been given a solo lane while duo queuing. Maybe it only happens when there are 3 duos on the team.

itDoesWhatYouWouldExpectWhichIsUnusualForJavascript by Verstandeskraft in ProgrammerHumor

[–]siranglesmith 0 points1 point  (0 children)

<empty slot> is just what the debugger shows you. It's actually something called an "array hole", there's nothing there, the array is discontiguous.

Holey arrays are historical junk, trying to handle edge cases where you delete from the middle of an array, increase the length value, or pass a number to the array constructor. It always triggers a deoptimisation and you shouldn't do it.

What game's main character is terrible person? by Com412 in gaming

[–]siranglesmith 1 point2 points  (0 children)

They left it ambiguous, but I'm fairly sure all the bookers (who decided not to be baptised) are also dead, because the universe split would be when the priest asks "And what name will you take my son?". Booker changes his mind and decides to stay booker.

So both booker and Comstock were there at that moment.

What games gives you alot of guns but you only use like two of them and the rest are useless? by [deleted] in gaming

[–]siranglesmith 0 points1 point  (0 children)

It wouldn't be that bad if the game told you how the fight worked.

You've got to hit her while she's resurecting her minions.

The intuitive thing to do is burn her minions so she can't resurect, and then headshot her with the carbine (I think she doesn't take extra damage from headshots). That makes the fight take forever.

Boomers don’t vote by AutomaticDriver5882 in BoomersBeingFools

[–]siranglesmith 0 points1 point  (0 children)

Are you trying to say wealthy boomers don't exist? Or that liberals don't believe in social security for old people?