HNHacker News
TopNewBestAskShowJobs

jakewins

3,662 karma · joined March 9, 2009

I build hardware for the energy transition at https://www.fluxrite.com

I previously built virtual power plants at Tibber, databases at Neo4j and fleet management Equipmentshare.

jake@davis-hansson.com https://tech.davis-hansson.com http://github.com/jakewins

submissionscomments
jakewins··on Librarians are dangerous
My brother, a middle school teacher, was talking about TikTok yesterday. Every 2 years he gets a new batch of 10-year-olds.

They all have a “class chat”, and it is used daily for relentless cyber bullying. The current trend TikTok is pushing this month is to push the boundaries of calling black kids the n-word without explicitly saying the word. There is one little black girl in his class.

He says every class is the same, horror ideas pushed by edge lords TikTok algos push on the kids. Relentless daily bullying. And unlike bullying on the playground or at the boys and girls club.. there is no realistic way for adults to intercede beyond disconnecting their kid, shutting them out of the social context entirely.

jakewins··on Frankenstein's `__init__`
There is no contradiction between “constructors cannot fail” and “fail early”, nobody is arguing the constructor should do fallible things and then hide the failure.

What you should do is the fallible operation outside the constructor, before you call __init__, then ask for the opened file, socket, lock, what-have-you as an argument to the constructor.

Fallible initialisation operations belong in factory functions.

jakewins··on Frankenstein's `__init__`
This is the exact opposite? They explicitly encourage doing resource-opening in the __enter__ method call, and then returning the opened resource encapsulated inside an object.

Nothing about the contract encourages doing anything fallible in __init__

jakewins··on Finding Signal in the Noise: Machine Learning and the Markets (Jane Street)
I’m intrigued as well.. My experience is notebooks struggle as a format for production code. We encourage people who work heavily in notebooks to use them for exploratory work, but choose other tools when it comes time to ship.

When you are exploring something, experimenting, showing.. it’s great; train-of-thought structure, APIs like Pandas optimised for writing and terseness etc.

But when you have a piece of code that will lose a million dollars a minute if someone ships a bug, and which will be maintained by many engineers over many years, then you really want a format that’s optimised for long-term maintenance, incremental change, testability, and APIs optimised for readers.

jakewins··on The European VAT Is Not a Discriminatory Tax Against US Exports
I still don’t follow. If the VAT was completely removed, US businesses would still pay state sales taxes on inputs and EU manufacturers would not?

The two things seem unrelated?

jakewins··on The European VAT Is Not a Discriminatory Tax Against US Exports
I’ve heard it’s also liked among economists because it’s like.. “sound”, somehow, or “efficient” as far as taxes go? Like a lot of special taxes, tariffs, deductions have super complex side effects, kickbacks, unexpected payees and loopholes.. but as I understand VAT is relatively “sane” on paper?

But also there was something about taxing consumption that was bad somehow.. is it regressive? I don’t remember. Feels “flat”, but maybe not?

jakewins··on The European VAT Is Not a Discriminatory Tax Against US Exports
Sorry I don’t follow - how does VAT make US exporters pay more than domestic EU manufacturers? They are both subject to the same VAT, or?
jakewins··on Balcony solar is taking off
Huh, for some reason I assumed the balcony kits would be… “dumber”.

Either way, I’ve installed many panels with exactly these little boxes clipped to the back of them, and there is nice clean DC power to pull directly off the panel if you like by just disconnecting the inverter

jakewins··on Balcony solar is taking off
I’ve not installed these balcony kits, but I’d be surprised if they used microinverters..

Either way, there is no issue using the panels in the kit you linked to in the way described; they are separate panels with standard MC4 connectors. Just unplug the inverter and plug in the grid forming one.

jakewins··on Balcony solar is taking off
> As to legalities....,if there is no regulation adressing it, its legal, beurocracys hate that, but there it is.

This is not law works. Either way there absolutely is regulation in minute detail about backfeeding power into your home, in any jurisdiction in EU or USA I’m aware of

jakewins··on Balcony solar is taking off
Yes but they are saying you could - in a power outage - use just the panels, disconnecting them from the grid tie inverter and instead plugging them into a regular off grid charge-controller+battery+inverter setup.

That would cost a bit, but would let you use the same panels for emergency power

jakewins··on Patterns for Building Realtime Features
In general you do it by doing a failover behind some variation of a reverse proxy.

If you can start new instances quickly and clients can handle short delays you can do it by just stopping the old deployment and starting the new one, booting off of the snapshotted state from the prior deployment.

If you need “instant” you do it by implementing some form of catchup and then fail over.

It is a lot easier to do this if you have a dedicated component that ”does” the failover, rather than having the old and new deployments try to solve it bilaterally. Could just be a script ran by a human, or something like a k8s operator if you do this a lot

jakewins··on The legacy of lies in Alzheimer's science
How is that correction mechanism supposed to work though? Do you mean the peer review process?

Friends in big labs tell me they often find issues with competitor lab papers, not necessarily nefarious but like “ah no they missed thing x here so their conclusion is incorrect”.. but the effect of that is just they discard the paper in question.

In other words: the labs I’m aware of filter papers themselves on the “inbound” path in journal clubs, creating a vetted stream of papers they trust or find interesting for themselves.. but that doesn’t provide any immediate signal to anyone else about the quality of the papers

jakewins··on Show HN: voidDB – A transactional key-value DB written in Go for 64-bit Linux
It always made me happy to hack nearby the Neo4j page cache "Muninn", because it meant I'd pass by Chris Vest's poem and giant ascii Raven: https://github.com/neo4j/neo4j/blob/release/5.26.0/community...
jakewins··on DeepSeek's AI breakthrough bypasses industry-standard CUDA, uses PTX
Not in HFT, but I guess maybe for being very fast running optimization solvers and forecast models etc? Essentially compute models for ultimately driving market decisions based on lots of input data

We do a lot of forecasting and solvers where I am, just run them on CPUs though.. but maybe if you’re wanting to compete on speed you would?

jakewins··on Sweden Seizes Ship Suspected of Baltic Sea 'Sabotage'
Finnish authorities denied those reports in Lloyds List FWIW: https://www.iltalehti.fi/kotimaa/a/3fa30bba-6925-49ac-8c49-c...

But also yeah, the opinion of authorities I see quoted in Swedish and Finnish press has been very clear they don’t think this is accidental.

I’ve lived by the Baltic for much of my life, had many many years of nothing like this, then suddenly every week Russian ships “accidentally” cuts critical cables.

No reason to spread rumours, that’s how seeds of doubt are sown; the evidence is plain as day without manufactured stories

jakewins··on MessagePack: It's like JSON, but fast and small.
CBOR is a clone of msgpack: https://en.m.wikipedia.org/wiki/CBOR
jakewins··on How to Debounce a Contact (2014)
There was some article from early instagram times about this the other week - that an innovation there was that they started the upload as soon as the picture was taken, so after the user filled out the caption part and hit “submit”, the “upload” was instantaneous
jakewins··on I automated my job application process
But like.. what happens after this supposed trick? I don’t understand how they wouldn’t just be fired after the first week if they can’t actually do the job?

Is it that they are applying to places where you don’t pair program?

jakewins··on Borrow Checking, RC, GC, and Eleven Other Memory Safety Approaches
Do you have any recommended reading material on this?

Intuitively it feels like making it concurrent should do the opposite of making GC deterministic! I’d love to read something showing that intuition is wrong

jakewins··on How much memory do you need in 2024 to run 1M concurrent tasks?
If the example was extended to, say, once the sleep is completed then parse and process some JSON data (simulating the sleep being a wait on some remote service), then how would memory use be affected?

In the Go number reported, the majority of the memory is the stack Go allocated for the application code anticipating processing to happen. In the Node example, the processing instead will need heap allocation.

Point being that the two numbers are different - one measures just the overhead of the runtime, the other adds the memory reserved for the app to do work.

The result then looks wasteful for Go because the benchmark.. doesn’t do anything. In a real app though, preallocating stack can often be faster than doing just-in-time heap allocation.

Not always of course! Just noting that the numbers are different things; one is runtime cost, one is runtime cost plus an optimization that assumes memory will be needed for processing after the sleep.

jakewins··on How much memory do you need in 2024 to run 1M concurrent tasks?
I mean this is subjective, but as long as it’s clear that one number is “this is the memory the runtime itself consumes to solve this problem” and the other number is “this is the runtime memory use and it includes pre-allocated stack space that a real application would then use”, sure

Point being: Someone reading this to choose which runtime will fit their use case needs to be carefully to not assume the numbers measure the same thing. For some real world use cases the pre allocated stack will perform better than the runtimes that instead will do heap allocations.

jakewins··on How much memory do you need in 2024 to run 1M concurrent tasks?
You know what I mean. If this was a real world program where those million tasks actually performed work, then this stack space is available for the application to do that work.

It’s not memory that’s consumed by the runtime, it’s memory the runtime expects the program to use - it’s just that this program does no useful work.

jakewins··on How much memory do you need in 2024 to run 1M concurrent tasks?
The accounting here is weird though; Go isn’t using that RAM, it’s expecting the application to. The reason that doesn’t happen is because it’s a micro benchmark that produces no useful work..

The way the results are presented a reader may think the Go memory usage sounds equivalent to the others - boilerplate, ticket-to-play - and then the Go usage sounds super high.

But they are not the same; that memory is in anticipation of a real world program using it

jakewins··on How much memory do you need in 2024 to run 1M concurrent tasks?
Fair or not, it’s a strange way to count - Go isn’t using that RAM. It’s preallocating it because any real world program will.
jakewins··on Jepsen: Bufstream 0.1
Auto commit has always seemed super shady. Manual commit I have assumed is safe though - something something vector clocks - and it’d be really interesting to know if that trust is misplaced.

What is the process and cost for having you do a Jepsen test for something like that?

jakewins··on Hazel: A live functional programming environment featuring typed holes
This is probably naive but: How does this differ from something like “declare a type, implement it with methods that all throw NotImplementedException”?

As in, is this “just” a less boilerplate-heavy version of that, or is it more capable?

jakewins··on Hazel: A live functional programming environment featuring typed holes
Well, regression in that feature set, but it’s better in other features, many of which drove people off of Eclipse.

When it worked, it was really, really good, agree. My experience was that it usually didn’t though, swap branches a few times and the caches would be broken, time for “invalidate caches and restart”. Multiple times per week, each time it’d take an hour to re-index.. that was a lot of time we got back again when we switched to IntelliJ

jakewins··on Google Funding Construction of Seven U.S. Nuclear Reactors
Intermittent and unreliable are two different things.

Renewables are intermittent and reliable; if a wind producer has bid into the day-ahead auction, you can expect with very high reliability they will deliver as bid.

Nuclear is great, so is zero-marginal-cost energy producers :)

jakewins··on Do not use secrets in environment variables
So don’t provide secrets to your service via environment variable, it can leak?

Instead, expose all your secrets via a public API with IP filtering, then give the credentials to this service to your app - as an environment variable - and voila!

This just seems like increasing complexity in a part of your system that should be as simple and non-dynamic as humanly possible, for the upside of.. much larger attack surface?

We inject secrets, as env vars, in each Deployment. No runtime access to any secrets store, gives the ability to generate new secrets for each deployment, and minimal complexity for such a critical aspect of the system.

← PreviousPage 4 of 19Next →