ukoki

Joined 14 years ago

Karma
1,200
Submissions
362
Member since
Apr 13
Software developer currently working in London.
View on Hacker News

Recent submissions

Comment · 3 months ago
I have a blanket, unignorable 'files must be <= 1000 lines' lint for my Rust projects for exactly this reason. Exploring large files is _costly_ for agents, so it's much better to lean into the filesystem hierarchy to a greater extent than you would normally with a team of human developers.
Comment · 3 months ago
The solution is to mandate that websites are built for browsers/devices as much as they are for humans. That way you never see a cookie banner because you've set up your device to never accept marketing cookies; A Google Maps link clicks through to Google Maps because you told your browser Google Maps was your preferred online mapping tool.
Comment · 3 months ago
This reminds me of my experience as a senior contractor joining teams that seem to enjoy endless discussion. For example, when implementing a new feature using an open-source library or framework they will want to make a prototype of all possible libraries, make a report about each of them, have some big discussions about which to choose, and only _then_ start the real implementation. My advice is always to just pick the one your gut tells you is the right one -- if the prototype works, then that _is_ the implementation and we can stop considering alternatives unless we have a good reason to reconsider them.

If a decision is hard to make, its often because the differences are small, and therefore it doesn't matter much and you might as well decide by dice-roll.

Comment · 3 months ago
Only the median (or pair around the median) needs to be sorted, the other numbers can be unsorted :)
Comment · 6 months ago
> lack of automated testing and TDD

Rust has testing in the standard library -- IMHO Bevy is far easier to test than most game engines because it's "just rust". You can test game logic by starting headless apps, proding the ECS, and making assertions on the results.

For acceptance tests I've dusted off cucumber (after ten years of not thinking about BDD), as I it works great with Bevy

Comment · 7 months ago
If you get paid by the government to do research you should make all your raw data, code, results etc, accessible to the public.

If it then turns out any of it is fabricated, you should be personally liable for paying it back

Comment · 9 months ago
Not OP but I'm currently make a city-builder computer game with a large procedurally-generated world. The terrain height at any point in the world is defined by function that takes a small number of constant parameters, and the horizontal position in the world, to give the height of the terrain at that position.

I need the heights on the GPU so I can modify the terrain meshes to fit the terrain. I need the heights on the CPU so I can know when the player is clicking the terrain and where to place things.

Rather than generating a heightmap on the CPU and passing a large heightmap texture to the GPU I have implemented the identical height generating functions in rust (CPU) and webgl (GPU). As you might imagine, its very easy for these to diverge and so I have to maintain a large set of tests that verify that generated heights are identical between implementations.

Being able to write this implementation once and run it on the CPU and GPU would give me much better guarantees that the results will be the same. (although necause of architecture differences and floating point handling they the results will never be perfect, but I just need them to be within an acceptable tolerance)

Comment · 9 months ago
Interesting to consider the effects of GLP-1 drugs on the environment then
Comment · 11 months ago
I don't think its about profits, its about incentivising using as many AWS products as possible. Consider it an 'anti-lock-in fee'
Comment · 1 year ago
First I thought "WTF why" and I'm still thinking "WTF why"
Comment · 1 year ago
> If anything they're a hindrance.

Absolutely. As a brit used to waiters and waitresses in the UK and Europe generally leaving me alone until I ask for something, I find the constant fawning interruptions from American service staff cringe-inducing.

A refreshing aspect of US culture is the lack of a historical class system and associated cultural baggage that we have in the UK. So I find it so strange that once you step into a restaurant you are forced into this weird servant/master cosplay where you dictate the server's livelihood based on how you happen to be feeling that day and the resulting whim of your pen writing on the tip line.

Comment · 1 year ago
it's the critical insight I was missing!
Comment · 1 year ago
Ok so what if I run the website in a VM allowing full execution of ad/tracking code, and then stream the video to a "browser" that blocks out the adverts?

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton