413 karma · joined August 16, 2024
Memory safety and thread safety are causes of heisenbugs. However there are other causes. Rust don't catch all heisenbug. But not being perfect doesn't mean it's useless (perfect solution fallacy).
The article has some valid points but is full of ragebait exaggeration.
> While UUIDv7 still contains random data, relying on the primary key for security is considered a flawed approach
The correct way is 1. generate ID on server side, not client side 2. always validate data access permission of all IDs sent from client
Predictable ID is only unsafe if you don't validate data access permission of IDs sent from client. Also, UUIDv7 is much less predictable than auto-increment ID.
But I do agree that having create time in public-facing ID can leak analytical information.
If your security relies on attacker don't know your ID (you don't do proper data permission check), your security is flawed.
https://github.com/ziglang/zig/issues/2647
You have to workaround by things like passing into a pointer to error object.
In my opinion the higher priority task is to optimize the query in backend so that it can refresh quickly. If loading is quick enough then that edge case will be less likely to happen.
One of the innovative point of Pony is the iso reference. iso reference means that an object graph is accessible from only that iso reference. It avoids sharing mutable data.
If a function can both insert and update, it should be called "put". Using "update" is misleading.
That's why rigid language like Rust is suitable for mature domains (like rewriting an existing app in Rust) where most things are known, instead of new and quickly iterating things (many unknown unknown). https://loglog.games/blog/leaving-rust-gamedev/
https://github.com/HonestyAGI/LLM-Fingerprint/issues/3
Sorry for submitting without carefully checking.
The correct way of fixing SQL injection is to use prepared statement and parameters.
Other examples: Windows allows software to do bad things, having no proper permission control (to maintain compatibility). Antimalwares scan applications by matching patterns of virus code, but has many false positives and false negatives. This causes many troubles (kill innocent software, scanning cost performance, etc.) because it does not fix from root case (proper permission management).
But often the problem of language can be partially solved by IDE. IDE can already generate if err != nil branches. Goland can fold if err != nil branches. https://github.com/golang/vscode-go/issues/2311