HNHacker News
TopNewBestAskShowJobs

tynorf

96 karma · joined October 3, 2017

[ my public key: https://keybase.io/tynor; my proof: https://keybase.io/tynor/sigs/cDld0ea8BUMbX4Blb2Hs-zUV9Cp9rGQDSu7I4SGZXeI ]
submissionscomments
tynorf··on New 14‑inch MacBook Pro with M6
While I was expressing an ideal setup, it isn’t all or nothing. A single backup is still better than none at all.

I suppose I didn’t specify exactly what I would recommend to someone who thinks it’s too hard, so here is that:

1. Install Backblaze. This is basically fire and forget. 2. (1) is enough for most people, but if interested (and on a Mac, which is what I’m familiar with), plug in an external SSD once a week or so for Time Machine. Setup involves clicking on the drive in the setup wizard and specifying an encryption password.

I don’t know about “ultra” robust, but this gives you protection from accidental deletions, natural disasters happening to your computer, hardware failures, and corruption from software bugs. The ongoing maintenance is plugging in a hard drive once a week.

If that is too much effort, just (1) provides natural disaster and hardware failure protection. It helps somewhat with the others but Backblaze only saves versions for 60 days and that’s a tight window to notice subtle corruption of e.g. your photos.

tynorf··on New 14‑inch MacBook Pro with M6
> PSA to make sure devices with non-removable storage are backed up!

Really this should be devices full stop. Also, "backed up" should include no fewer than two backups on different media and in different physical locations e.g. Time Machine to an external SSD _plus_ continuous cloud backup.

tynorf··on Memory prices climb 500% in 12 months
They still need to buy said RAM from all the same players.
tynorf··on ArenaAllocators don't play nicely with ArrayLists
FWIW, if you aren’t interleaving other allocations (which includes on other threads), the ArenaAllocator in Zig doesn’t have this problem. If you attempt to resize the most recent allocation, it will do so in place if possible.

https://ziglang.org/documentation/0.16.0/std/#std.heap.Arena...

tynorf··on Lightning Memory-Mapped Database Manager (LMDB) 1.0
IIRC: it is to leverage the OS page cache rather than having a separate buffer pool in user land. By default lmdb uses normal pwrite/fsync for the write path, but can optionally use a writable mapping and (presumably) msync.

However, some people think there are problems with this usage: (pdf warning) https://www.cidrdb.org/cidr2022/papers/p13-crotty.pdf

tynorf··on Why users cannot create Issues directly
The computer has 18GB of total RAM so I would hope that it’s already trying to conserve memory.

It’s kind of humorous that everyone interpreted the comment as complaining about Chrome. For all I know, it’s justified in using that much memory, or it’s the crappy websites I’m required to use for work with absurdly large heaps.

I really just meant that at least for work I need more than 8GB of RAM.

tynorf··on Why users cannot create Issues directly
Chrome on my work laptop sits around 20-30GB all day every day.
tynorf··on Common Mistakes in Modularisation
Perhaps a small nit, but the “design space tree” looks more like a directed graph.
tynorf··on Duplicity: Encrypted bandwidth-efficient backup
You can try setting `export PYTHONWARNINGS="ignore"` to suppress warnings.
tynorf··on Active turbulence cancellation makes bumpy flights smoother
Anecdotally, I fly round trip out of SEA ~3 times a year and experience very bad turbulence on about half the flights. Earlier this year it was bad enough to suspend drink service.
tynorf··on What I learned getting acquired by Google
> At Amazon you can't even open the building next door without approval.

This is not true.

tynorf··on System Design 101
This is a very important point.

I'd argue all these "publish your DB schema as a GraphQL endpoint" frameworks that seem to proliferate have done a lot of damage to GraphQL's reputation. Strongly coupling data to presentation seems like such an obvious anti pattern, yet tools doing just that seem to be very popular for some reason.

tynorf··on Transactions Are Not Locks (2022)
You might be interested in this: https://brandur.org/idempotency-keys
tynorf··on Versioning data in Postgres? Testing a Git like approach
The objects directory stores every file (and tree, commit, etc). Pack files are an optimization storing diffs.
tynorf··on Database Performance at Scale – A free book
Cassandra does not make you immune to database issues: https://monzo.com/blog/2019/09/08/why-monzo-wasnt-working-on...
tynorf··on iPhone 15: users of Pro and Pro Max models complain of overheating issues
The interior has been aluminum, but the band around the outside has been stainless steel.

> Ceramic Shield front, Textured matte glass back and stainless steel design

https://support.apple.com/kb/SP875?viewlocale=en_US&locale=e...

tynorf··on Speed Up C++ Compilation
Yes, that would be a different reason to prefer worktrees (that I mostly agree with). I was responding to the specific storage space claim.
tynorf··on Speed Up C++ Compilation
FWIW, local git clones use hard links for object files, so share a lot of their data.

https://www.git-scm.com/docs/git-clone#Documentation/git-clo...

tynorf··on How small is the smallest .NET Hello World binary?
I'm pretty sure part of the contract with gzip (and compression in general) is that applying it N times is undone by decompressing N times.

The size definitely gets bigger with each iteration:

  $ echo text >0.txt
  $ for i in {0..9}; do                             
  gzip <$i.txt >$((i + 1)).txt
  done
  $ ls | sort -n | xargs -n1 wc -c
       5 0.txt
      25 1.txt
      46 2.txt
      69 3.txt
      82 4.txt
     105 5.txt
     120 6.txt
     143 7.txt
     161 8.txt
     184 9.txt
     207 10.txt
tynorf··on AWS us-east-1 outage
Something like this? https://stop.lying.cloud/
tynorf··on fs.promises.readFile is 40% slower than fs.readFile
I believe orf is talking about the read(2) syscall, which is blocking.
tynorf··on Sick of spending time on Auth, we built an open source 'Stripe for Auth'
OWASP is a good resource for web security related topics. i.e. https://cheatsheetseries.owasp.org/cheatsheets/Authenticatio...
tynorf··on REST vs. GraphQL – A search for evidence on which is better
I think the classic example is article list with author details. You load the articles (one query), then for each article you load its author (N queries). Naive use of an ORM causes this:

  articles = Article.load(limit=10)
  for article in articles:
    # .author implicitly runs a query
    author_name = article.author.name
This can be avoided in ORMs providing prefetching (e.g. `Article.load(eager_load='author')`).
tynorf··on Strict APIs vs. Forgiving APIs
I believe being lenient in accepting input is what leads to SSRF attacks (HTTP request smuggling via disagreeing `transfer-encoding` and `content-length` headers).
tynorf··on Dockerfile Security Best Practices
Probably either via a third party service (such as AWS secrets manager), or mounted as files scoped to the user your process is running as (which is not root, right? :) ).
tynorf··on Why is Apple acting like an asshole?
Just a point of clarification: native app notifications on iOS are absolutely opt-in. If the app wants to send notifications it requires a dialogue and user confirmation.

Disappointingly, Apple makes an exception for their first party apps.

tynorf··on Firefox 80
Out of curiosity, how many windows/tabs? I routinely launch FF with dozens of windows/hundreds of tabs and I've never had macOS kernel panic in that case.
tynorf··on I Want Off Mr. Golang's Wild Ride
Curious: what is your definition of strongly typed, contrasted with weakly typed? How about static vs dynamic?
tynorf··on Let's Destroy C
I haven't actually watched it in a while, but are you referencing this talk by Chandler Carruth? https://youtu.be/yG1OZ69H_-o
tynorf··on How to Exit Vim
Unfortunately:

  E183: User defined commands must start with an uppercase letter
Page 1 of 2Next →