HN user

tomjen3

9,857 karma

Software Dev (yeah, that is a first on this site)

Chat with me at tomjen@tomjen.net

Posts3
Comments9,893
View on HN

I think that is probably too conspiratorial, if only for the reason that Europe is not gonna go along with it.

I work in tech in Europe and we have a fair number of customers who arelike. we can accept AI, but they must keep the data in Europe. That's trivial with an open weight. We literally cannot do it with Fable.

We have come to a consensus. That is, A, you use the raw input right up till the very last second that you can and B you use the technology specific escaping APIs.

In the case of writing to the DOM, that means you use .innerText rather than .innerHTML. In the case of writing to a database, that means you use the driver and insert variables rather than directly into the string. Both of these are technology-specific escaping APIs. It's just that the browser is much better at making sure HTML is passed safely than you are.

I am curious what is your write pattern? How long do you keep the transactions open for?

There are definitely cases where a single lock does not fit. Even though you can only write one at a time, the transactions ideally should be open for a very short period. That way the throughput, as measured in writes per second, should still be really high.

If there is some other network call in there, SQLite is not a good fit for it and you should definitely move to some other database.

As for write queue, SQLite has that built in if you do transactions — it should unlock other transactions when one is closed.

If you specify IMMEDIATE as the transaction type, it should try to get an exclusive write lock and will timeout after the default time of 30 seconds.

Use WAL (yes this should be the default, or at least explained much better) and you can have one writer, many readers.

Don't move to the network unless you have to - every single request gets massively slowed down because it has replaced local reads with network connections.

Of course if you are building a startup you must consider scaling.

I am biased but I think if they really believed what they were saying, they would be a lot more humble about it.

I suspect what happened is the classic problem: you were sincere, then someone showed you a pile of money bigger than you could possibly imagine and you started to make excuses - Anthropic has a lot of EA people, so the excuse "Imagine how many lives you could save with this much money"[0] is very tempting, especially if all you have to do is diverge slightly from your plan.

[0]: the excuse is even true! You can get a lot of malaria nets/vaccines for 1 million.

Go does not give you control. Much of the speed comes from choosing the right algorithms - including memory management. In Go you have GC, you don't have that in Zig.

Linked lists are a lot less slow if you use Arena allocation around your hotspots and make sure to allocate space for as many as you thing you need, since they will be carved out of a contigious block of memory and will stay in CPU cache.

Golang also requires you to write more code, as it lags Zigs try operator.

Control. Its a replacement for C that is a lot nicer to work with.

So basically if you either need your Python code to interact with a native library or need more control in a specific place, you can use Zig there.

Zig makes it trivial to control which part of the code e.g allocate memory, so you can guarantee that your rendering or audio loop has no stuttering.

I would still keep Python as the main driver for where dev speed is the most important part.

You can discard a variable like so:

_ = variable_to_discard

I am sorta unsure why Zig doesn't have multiline comments, but its also not at version 1 yet, so that will likely come, along with better IDE support.

That is interesting. And it's an AI critique I haven't heard before.

Would you consider it possible that the way non-intentionally placed items break the game immersion for you is because they appear in such a way that you think you can interact with them in a certain way, but you can't?

Like if there's an extra door in the house you're trying to get into, but that door doesn't really open, then in your mind that breaks the integrity of the game's systems. If so, I think the LLM response is that there are no more doors that don't open and that the world can be generated as needed.

No computer can handle the complexity of even a small town. But it would be possible, at least in the future, to generate the part of the world you interact with, which would heighten the emersion.

I believe the world would be better of without alcohol for consumption, yes.

The only real benefits are not being the one outside the group, and the downsides include liver damage, social damage, massively higher risk for falling, drunk driving,...

More to the point, alcohol would never be permitted if it was invented today. Marijuana might.

Project Gutenberg is awesome and amazing.

I was visting the ruins of a monestary the other day, and one of the texts listed that it had a library of 320ish books.

I chucked because I have almost 200 books in my personal Kindle library, but I was wrong. I actually have 75000+ books, thanks to Project Gutenberg.

I just haven't downloaded them all yet.

Its meaningless to decriminalize using it, since it does not give big benefit of replacing narco terrorists producers with pure, controlled stuff from legal pharma companies.

The world is obviously better of without drugs, but given that is not going to happen, the question to decide is: is the world better of with drugs from legal pharmacutical companies, or (somewhat) restricted access to drugs through an illegal system?

Decrimininalizing drug use is the worst of both worlds: you get more drug access, but it still happens through the illegal system and benefits narco terrorists.

If you don't want to put drug users in jail (you cannot reasonably fine homeless people), you can offer drug courts and diversionary programs.

You need the federal government to do what it did with Marijuana (which is still federally illegal), to be able to try the other choice.

I have done as OP suggested and the main benefit is that I can move my email elsewhere.

For now my email is with Apple, since they offers email hosting as part of the icloud+ (or whatever its called). If they decide to die/enshittify, then I can move to another host without having to change any contacts.

One the other hand, since I did use my bare gmail for some years, I am still stuck with it, in case I have some service that depends on it.

That's certainly an interesting idea - mostly everybody should know someone who has a gmail account, so if you get a couple invites a month, that should be plenty and the setup would

Well I was about to say destroy scammers, but I just realized that they would send out spam to places where you could gamble your invites for Real Cash(TM) or just straight up buy them.

This would lower the creation of accounts, but then they would be rarer and worth more to spammers, since a spamming gmail would be rare.

And we would hear sob stories of people getting their accounts closed for inviting spammers.

I am not sure the backslash would be big if Gmail said that a year from now you would have to pay $9.99 per month to use your Gmail ($12.99 ad-free). I mean people would complain, but would that actually give a backslash? Especially if they made it easy for people to move their account elsewhere? People are used to paying a lot more for things outside of tech.

I suspect what is really holding them back is the loss of data, and the loss of the assumption that ~everyone has a Google account that they are logged into, which means they can be traced around the web. Google also benefits from this, since its anti-bot tool will be more accurate and less fustrating to users.

Being nerdy.

But also you don’t build these things when you need them (it will be too late), you need to build them before you need them.

They had to design a specialized verification function, which I imagine would be the easy way to break it.

The brilliant part of Bitcoin is that it uses very widely known crypto primitives - verification is the same as getting the right seed (you just happen to be told what the right seed is, rather than having to pay for it to be discovered).

I will happily stop and chat with you if you demonstrate that it is worth the time and interruption (if I was lost in thought, that will take at least 5-10 minutes to get back to).

If not, I will not let you know. I will just fume, blame and judge you for some time after.