<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Hacker News: grantwu</title><link>https://news.ycombinator.com/user?id=grantwu</link><description>Hacker News RSS</description><docs>https://hnrss.org/</docs><generator>hnrss v2.1.1</generator><lastBuildDate>Thu, 30 Apr 2026 02:17:38 +0000</lastBuildDate><atom:link href="https://hnrss.org/user?id=grantwu" rel="self" type="application/rss+xml"></atom:link><item><title><![CDATA[New comment by grantwu in "Colossus for Rapid Storage"]]></title><description><![CDATA[
<p>Isn't S3 Express not the same API? You have to use a "directory bucket" which isn't an object store anymore, as it has actual directories.<p>To be honest I'm not actually sure how different the API is. I've never used it. I just frequently trip over the existence of parallel APIs for directory buckets (when I'm doing something niche, mostly; I think GetObject/PutObject are the same.)</p>
]]></description><pubDate>Thu, 10 Apr 2025 18:05:22 +0000</pubDate><link>https://news.ycombinator.com/item?id=43646538</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=43646538</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43646538</guid></item><item><title><![CDATA[New comment by grantwu in "A 10x Faster TypeScript"]]></title><description><![CDATA[
<p>> By far the most important aspect is that we need to keep the new codebase as compatible as possible, both in terms of semantics and in terms of code structure. We expect to maintain both codebases for quite some time going forward. Languages that allow for a structurally similar codebase offer a significant boon for anyone making code changes because we can easily port changes between the two codebases. In contrast, languages that require fundamental rethinking of memory management, mutation, data structuring, polymorphism, laziness, etc., might be a better fit for a ground-up rewrite, but we're undertaking this more as a port that maintains the existing behavior and critical optimizations we've built into the language. Idiomatic Go strongly resembles the existing coding patterns of the TypeScript codebase, which makes this porting effort much more tractable.<p>--<a href="https://github.com/microsoft/typescript-go/discussions/411" rel="nofollow">https://github.com/microsoft/typescript-go/discussions/411</a><p>I haven't looked at the tsc codebase. I do currently use Golang at my job and have used TypeScript at a previous job several years ago.<p>I'm surprised to hear that idiomatic Golang resembles the existing coding patterns of the tsc codebase. I've never felt that idiomatic code in Golang resembled idiomatic code in TypeScript. Notably, sum types are commonly called out as something especially useful in writing compilers, and when I've wanted them in Golang I've struggled to replace them.<p>Is there something special about the existing tsc codebase, or does the statement about idiomatic Golang resembling the existing codebase something you could say about most TypeScript codebases?</p>
]]></description><pubDate>Tue, 11 Mar 2025 15:01:43 +0000</pubDate><link>https://news.ycombinator.com/item?id=43333156</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=43333156</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43333156</guid></item><item><title><![CDATA[New comment by grantwu in "Avoid the Nightmare Bicycle"]]></title><description><![CDATA[
<p>I haven't read "Changing Minds".<p>> As he points out: it would be terrible! We’d lose the intuitive understanding of how to use the gears to solve any situation we encounter. Which mode do you use for gravel + downhill?<p>I have no idea, actually, what gears I should use for gravel + downhill, which is surprising since about 6 years ago I biked from Pittsburgh to DC, which had a fairly long downhill section. I remember mostly coasting on that section. I might've stopped a few times to make sure my brakes could cool down. I don't think there is a wrong gear on a bicycle when coasting down on gravel?<p>Perhaps I am the user who does need a nightmare bicycle with a gravel + downhill button.</p>
]]></description><pubDate>Wed, 05 Mar 2025 06:50:53 +0000</pubDate><link>https://news.ycombinator.com/item?id=43263636</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=43263636</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43263636</guid></item><item><title><![CDATA[New comment by grantwu in "Hacking 700M Electronic Arts Accounts"]]></title><description><![CDATA[
<p>The timeline says that the initial report was 6/16 and the initial patches were 7/8 and 7/18.<p>It's not clear to me what was exploitable when.</p>
]]></description><pubDate>Tue, 05 Nov 2024 16:28:29 +0000</pubDate><link>https://news.ycombinator.com/item?id=42052847</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=42052847</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=42052847</guid></item><item><title><![CDATA[New comment by grantwu in "Who died and left the US $7B?"]]></title><description><![CDATA[
<p>> In exchange for such favorable terms (i.e., small carrying cost, matures on death), the bank will receive a share of the collateral’s appreciation (essentially amounting to “stock appreciation rights"), and this obligation will be settled upon the borrower’s death.<p>It's a loan in name only.<p>Regarding Bezos's selling of stocks - perhaps he has offsetting capital gains. See <a href="https://old.reddit.com/r/BuyBorrowDieExplained/comments/1f26rsf/buy_borrow_die_explained/lm3r09j/" rel="nofollow">https://old.reddit.com/r/BuyBorrowDieExplained/comments/1f26...</a></p>
]]></description><pubDate>Wed, 09 Oct 2024 19:20:52 +0000</pubDate><link>https://news.ycombinator.com/item?id=41791644</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=41791644</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=41791644</guid></item><item><title><![CDATA[New comment by grantwu in "Understanding ZFS Channel Programs"]]></title><description><![CDATA[
<p>I'm not following what you're saying. Why do we need a callback?<p>In this imaginary design, the syscalls you make would look something like:<p>- BeginChannelTx -> return ChannelTxID<p>- ReadZFSProperties(ChannelTxID, params) -> return data<p>- DestroySomeDatasets(ChannelTxID, params) -> ok<p>- CommitChannelTx(ChannelTxID)<p>Notably, DestroySomeDatasets doesn't actually do any work. It merely records which datasets you want to destroy. There are no callbacks as far as I can see: there's no kernel thread waiting on a user thread to do something. This way also lets you express branching.<p>The drawback of this approach is you need a lock on all mutating administrative commands when you call BeginChannelTX. I talked to a ZFS dev, and he said that with ZFS' design, that's actually the txg sync lock. This means that while reads will proceed, writes will only proceed for a short period of time, and nothing will make it to disk. The overhead of making all these syscalls was also judged to be problematic.</p>
]]></description><pubDate>Thu, 09 Sep 2021 23:22:44 +0000</pubDate><link>https://news.ycombinator.com/item?id=28475890</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=28475890</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28475890</guid></item><item><title><![CDATA[New comment by grantwu in "Understanding ZFS Channel Programs"]]></title><description><![CDATA[
<p>> Blocking within one, with those locks acquired, and thunking back down to userspace, would mean that 1. a CPU core, and 2. the filesystem itself, would both be tied up indefinitely until that callback thunk returns. If it ever does!<p>In this theoretical design, you could just block all other administrative modifications. I don't think you need to tie up an entire CPU core, and I'm fairly sure that these zfs operations don't block regular reads and writes.<p>I think you had it right in your initial comment. There's no good way express branching with an implementation which incrementally submits operations to be committed as a batch. You'd have to take an admin lock on an entire zpool.<p>EDIT: talked to a zfs dev, said this would take the txg sync lock.</p>
]]></description><pubDate>Thu, 09 Sep 2021 22:52:52 +0000</pubDate><link>https://news.ycombinator.com/item?id=28475631</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=28475631</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28475631</guid></item><item><title><![CDATA[New comment by grantwu in "How We Went All In on sqlc/pgx for Postgres and Go"]]></title><description><![CDATA[
<p>Works as expected? Wouldn't that WHERE clause filter out all of the rows? Is that frequently desired behavior?</p>
]]></description><pubDate>Wed, 08 Sep 2021 23:01:58 +0000</pubDate><link>https://news.ycombinator.com/item?id=28464136</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=28464136</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28464136</guid></item><item><title><![CDATA[New comment by grantwu in "How We Went All In on sqlc/pgx for Postgres and Go"]]></title><description><![CDATA[
<p>I was really really excited when I saw the title because I've been having a lot of difficulties with other Go SQL libraries, but the caveats section gives me pause.<p>Needing to use arrays for the IN use case (see <a href="https://github.com/kyleconroy/sqlc/issues/216" rel="nofollow">https://github.com/kyleconroy/sqlc/issues/216</a>) and the bulk insert case feel like large divergences from what "idiomatic SQL" looks like. It means that you have to adjust how you write your queries. And that can be intimidating for new developers.<p>The conditional insert case also just doesn't look particularly elegant and the SQL query is pretty large.<p>sqlc also just doesn't look like it could help with very dynamic queries I need to generate - I work on a team that owns a little domain-specific search engine. The conditional approach could in theory with here, but it's not good for the query planner: <a href="https://use-the-index-luke.com/sql/where-clause/obfuscation/smart-logic" rel="nofollow">https://use-the-index-luke.com/sql/where-clause/obfuscation/...</a></p>
]]></description><pubDate>Wed, 08 Sep 2021 21:57:06 +0000</pubDate><link>https://news.ycombinator.com/item?id=28463549</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=28463549</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28463549</guid></item><item><title><![CDATA[New comment by grantwu in "A case against security nihilism"]]></title><description><![CDATA[
<p>Can someone explain why Blastdoor has been unsuccessful? Is it too hard a problem to restrict what iMessage can do?</p>
]]></description><pubDate>Tue, 20 Jul 2021 21:43:48 +0000</pubDate><link>https://news.ycombinator.com/item?id=27899777</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=27899777</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=27899777</guid></item><item><title><![CDATA[New comment by grantwu in "Making Rust as Fast as Go"]]></title><description><![CDATA[
<p>Can you point to a source that defines Levenstein distance as only referring to bitstreams?<p>A translation of the original article [1] that introduced the concept notes in a footnote that "the definitions given below are also meaningful if the code is taken to mean an arbitrary set of words (possibly of different lengths) in some alphabet containing r letters (r >= 2)".<p>And if you wish to strictly stick to how it was originally defined, you'd need to only use strings of the same length.<p>More recent sources [2] say instead "over some alphabet", and even in the first footnote, describe results for "arbitrarily large alphabets"!<p>[1] <a href="https://nymity.ch/sybilhunting/pdf/Levenshtein1966a.pdf" rel="nofollow">https://nymity.ch/sybilhunting/pdf/Levenshtein1966a.pdf</a><p>[2] <a href="https://arxiv.org/pdf/1005.4033.pdf" rel="nofollow">https://arxiv.org/pdf/1005.4033.pdf</a></p>
]]></description><pubDate>Sun, 03 May 2020 20:13:59 +0000</pubDate><link>https://news.ycombinator.com/item?id=23061519</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=23061519</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=23061519</guid></item><item><title><![CDATA[New comment by grantwu in "Show HN: Shishua – Fast pseudo-random generator"]]></title><description><![CDATA[
<p>Where? CTRL-F Randen doesn't show anything, and the Randen repo claims it's faster than ChaCha8.</p>
]]></description><pubDate>Sun, 19 Apr 2020 05:37:04 +0000</pubDate><link>https://news.ycombinator.com/item?id=22913802</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=22913802</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22913802</guid></item><item><title><![CDATA[New comment by grantwu in "Ask HN: Who is hiring? (August 2019)"]]></title><description><![CDATA[
<p>DevOps engineer link appears to 404.</p>
]]></description><pubDate>Fri, 02 Aug 2019 07:05:03 +0000</pubDate><link>https://news.ycombinator.com/item?id=20591132</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=20591132</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20591132</guid></item><item><title><![CDATA[Sourcegraph free user quota lowered to 50]]></title><description><![CDATA[
<p>Article URL: <a href="https://github.com/sourcegraph/sourcegraph/commit/e5a5479376798cefb884dda42ebb0376a78bf801#diff-f9e579844875cb46d3b49926faf8c740R160">https://github.com/sourcegraph/sourcegraph/commit/e5a5479376798cefb884dda42ebb0376a78bf801#diff-f9e579844875cb46d3b49926faf8c740R160</a></p>
<p>Comments URL: <a href="https://news.ycombinator.com/item?id=19824721">https://news.ycombinator.com/item?id=19824721</a></p>
<p>Points: 2</p>
<p># Comments: 0</p>
]]></description><pubDate>Sat, 04 May 2019 05:58:24 +0000</pubDate><link>https://github.com/sourcegraph/sourcegraph/commit/e5a5479376798cefb884dda42ebb0376a78bf801#diff-f9e579844875cb46d3b49926faf8c740R160</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=19824721</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=19824721</guid></item><item><title><![CDATA[New comment by grantwu in "Hiring and the market for lemons (2016)"]]></title><description><![CDATA[
<p>Oh I guess we don't need maintenance then</p>
]]></description><pubDate>Fri, 13 Apr 2018 21:40:08 +0000</pubDate><link>https://news.ycombinator.com/item?id=16834122</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=16834122</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=16834122</guid></item><item><title><![CDATA[New comment by grantwu in "Approaches to PostgreSQL Replication and Backup"]]></title><description><![CDATA[
<p>I read "pull backups" as "restore from backup" not "make backups".</p>
]]></description><pubDate>Sat, 24 Feb 2018 07:30:48 +0000</pubDate><link>https://news.ycombinator.com/item?id=16452210</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=16452210</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=16452210</guid></item><item><title><![CDATA[New comment by grantwu in "Nix 2.0 Released"]]></title><description><![CDATA[
<p>Did you even read my comment?  I acknowledged that.</p>
]]></description><pubDate>Fri, 23 Feb 2018 17:44:07 +0000</pubDate><link>https://news.ycombinator.com/item?id=16447892</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=16447892</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=16447892</guid></item><item><title><![CDATA[New comment by grantwu in "Nix 2.0 Released"]]></title><description><![CDATA[
<p>> So yes, if you need 100% deterministic, Nix is your guy.<p>There are two orthogonal problems here:  a lack of package isolation and nondeterminism.<p>Nix isolates packages, such that updating one package has no impact on any other packages (with unavoidable exceptions like the graphics driver, presumably).<p>You're right that package isolation isn't much of a problem on non-rolling distros.  One of the benefits of Nix is that you get some of the stability and predictability of an LTS distro with the freshness of a rolling distro when desired, without having to deal with package conflicts.<p>Incidentally, Nix doesn't need to be used in a deterministic manner.  In fact, I don't think most desktop users of Nix care too much about determinism for most packages they run.  I certainly don't; I'm happy to follow along with whatever arrives in my channel.  Nix has features that support determinism, and I'm certainly glad they exist for when I end up needing them, but they're not necessarily why people use Nix.<p>> Obviously, stateless is valuable.<p>When I said "stateless", I was referring to the whole "cattle, not pets" view of servers, where the running state of any particular server is unimportant, with nothing in the filesystem being of value.  I was arguing that needing to build a new image and reboot in order to change which packages are installed are a poor fit for the desktop use case, where frequent reboots are much more inconvenient than for the server use case.<p>I'm not sure what taohansen meant when they used the word "stateless"; they seem to mean something different when they say that.<p>Anyways, this point is not really applicable anymore, since you've stated:<p>> You can install your packages and use them when you like, without requiring a rebuild.<p>Presumably if you install additional packages uncontrolled by your tooling, then your systems can start to drift away from each other.<p>Nix does not have this compromise; there's no build step.  At any given point in time you can reproduce whatever configuration you have on one machine on another machine, regardless of how piecemeal you arrived at that configuration.</p>
]]></description><pubDate>Fri, 23 Feb 2018 17:03:51 +0000</pubDate><link>https://news.ycombinator.com/item?id=16447573</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=16447573</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=16447573</guid></item><item><title><![CDATA[New comment by grantwu in "Nix 2.0 Released"]]></title><description><![CDATA[
<p>It's not clear to me that this really solves the same problems that Nix does.<p>I'd imagine this solution inherits any problems that pacman has.  The Arch wiki states that "if two packages depend on the same library, upgrading only one package might also upgrade the library (as a dependency), which might then break the other package which depends on an older version of the library." (<a href="https://wiki.archlinux.org/index.php/System_maintenance" rel="nofollow">https://wiki.archlinux.org/index.php/System_maintenance</a>)  This is one of the problems Nix does not have by design; in fact Nix lets you mix and match packages painlessly.<p>This also doesn't seem to allow unprivileged users to install packages, which is kind of a side benefit of using Nix.<p>Docker-esque solutions' issues with reproducibility are well known; I look at <a href="https://godarch.com/concepts/images/" rel="nofollow">https://godarch.com/concepts/images/</a>, particularly how packages are installed:<p><pre><code>  #!/usr/bin/env bash
  pacman -S steam --noconfirm
</code></pre>
and I see the same issues that <a href="https://blog.wearewizards.io/why-docker-is-not-the-answer-to-reproducible-research-and-why-nix-may-be" rel="nofollow">https://blog.wearewizards.io/why-docker-is-not-the-answer-to...</a> warns of.  Heck the author even admits this is the case in an adjacent comment:  "I want a machine that can be declared and rebuilt deterministically <i>(at least semi-deterministically, rolling distro and all)</i>" (emphasis mine).<p>Also, frankly, I don't want to run my personal computer like a server, with complete immutability and the need to build fat image files every time I want to try out an additional program.  That seems to me like a workflow that's better suited for servers where spending a few minutes for a deploy isn't a blocking operation, and where stateless service design is considered best practice.</p>
]]></description><pubDate>Fri, 23 Feb 2018 15:10:44 +0000</pubDate><link>https://news.ycombinator.com/item?id=16446711</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=16446711</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=16446711</guid></item><item><title><![CDATA[New comment by grantwu in "Nix 2.0 Released"]]></title><description><![CDATA[
<p>What does... how is this relevant to anything I said?</p>
]]></description><pubDate>Fri, 23 Feb 2018 05:40:25 +0000</pubDate><link>https://news.ycombinator.com/item?id=16444484</link><dc:creator>grantwu</dc:creator><comments>https://news.ycombinator.com/item?id=16444484</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=16444484</guid></item></channel></rss>