HNHacker News
TopNewBestAskShowJobs

kiitos

797 karma · joined July 22, 2023

submissionscomments
kiitos··on The Theatre of Pull Requests and Code Review
i think you would benefit from some time in an organization that was not shitty
kiitos··on The Theatre of Pull Requests and Code Review
more or less the entire point of code review is to ensure that the reviewer fully understands the code that they review

i know that lots of orgs don't do it this way, but it's really important to make this point very clear: those orgs are wrong, and pathological, no matter how many of them there are

kiitos··on The Theatre of Pull Requests and Code Review
stacked PRs are wildly reviewer-hostile, please do not do them
kiitos··on The Theatre of Pull Requests and Code Review
the entire repo lives only on github as well, there is no meaningful difference between git commits and PR comments in a github-hosted repo
kiitos··on The Theatre of Pull Requests and Code Review
yeah, for sure -- avoid stacking changes in the first place! the purpose of PRs and code review is to establish a single unified shared context between multiple stakeholders. it's the author's responsibility to propose changes that are independent and coherent and easy to understand.
kiitos··on The Theatre of Pull Requests and Code Review
holy moly absolutely not

git is a means, not an end

code review is about the code as a unit whole, not the steps along the way!

kiitos··on The Theatre of Pull Requests and Code Review
> But yes, not everyone can or will write good commits.

some people treat commits as meaningful units of independent review, and some people treat them as savepoints and the PR as the only meaningful unit of review, it's a distinction of process, not purity -- both approaches are totally fine, one is not better than the other

git and commits and prs are means, not ends

kiitos··on The Theatre of Pull Requests and Code Review
code review isn't about diffs, it's about holistic changes to the project

the point is not queue progression, it is about dissemination of knowledge

one holistic change to a project = one PR

simple stuff really

kiitos··on The Theatre of Pull Requests and Code Review
minimizing reviewer context is one thing a PR can try to do, but it's not like that's any kind of universal most-important metric that every PR needs to optimize for, in fact very often minimizing reviewer context is in direct tension with making changes that are holistic and coherent

code review is meant to take time

kiitos··on The Theatre of Pull Requests and Code Review
git is a means, not an end

commits mean precisely what their author intend them to mean, nothing more

if you squash-merge every PR then history is clean where it matters

kiitos··on Cap'n Web: a new RPC system for browsers and web servers
> Why RPC? (And what is RPC anyway?)

RPC is an ambiguous and abstract umbrella-term for any request-response communication between two nodes that don't share the same memory space, usually over a network connection, and always via serialized bytes.

> Without RPC, you might communicate using a protocol like HTTP.

HTTP is probably the most common protocol for implementing RPC, indeed

> With HTTP, though, you must format and parse your communications as an HTTP request and response, perhaps designed in REST style.

yep! HTTP/REST is one good option, among many, for doing RPC communications

> RPC systems try to make communications look like a regular function call instead, as if you were calling a library rather than a remote service. The RPC system provides a "stub" object on the client side which stands in for the real server-side object.

Er, no, if you introduce the concept of "objects" you're now talking about something quite different than RPC, more akin to CORBA, which we well know now is not sound...

> When a method is called on the stub, the RPC system figures out how to serialize and transmit the parameters to the server, invoke the method on the server, and then transmit the return value back.

I mean, sure, but this is just normal serialization protocol stuff, right?

> The merits of RPC have been subject to a great deal of debate. RPC is often accused of committing many of the fallacies of distributed computing. But this reputation is outdated. When RPC was first invented some 40 years ago, async programming barely existed. We did not have Promises, much less async and await. Early RPC was synchronous: calls would block the calling thread waiting for a reply. At best, latency made the program slow. At worst, network failures would hang or crash the program. No wonder it was deemed "broken". Things are different today. We have Promise and async and await, and we can throw exceptions on network failures. We even understand how RPCs can be pipelined so that a chain of calls takes only one network round trip. Many large distributed systems you likely use every day are built on RPC. It works.

What a confusion of terms and concepts! Promises and async/await are language-level concepts, completely orthogonal to "RPC" which is a transport/wire-level concept -- what is happening here!! :o

> The fact is, RPC fits the programming model we're used to. Every programmer is trained to think in terms of APIs composed of function calls, not in terms of byte stream protocols nor even REST. Using RPC frees you from the need to constantly translate between mental models, allowing you to move faster.

i do not think RPC means what this author thinks that it means

kiitos··on Cap'n Web: a new RPC system for browsers and web servers
I am not really sure what you're talking about

RPC is "remote procedure call", emphasis on "remote", meaning you always necessarily gonna be serializing/deserializing the information over some kind of wire, between discrete/different nodes, with discrete/distinct address spaces

a client request by definition can't include anything that can't be serialized, serialization is the ground truth requirement for any kind of RPC...

a server doesn't provide "an object" in response to a query, it provides "a response payload", which is at most a snapshot of some state it had at the time of the request, it's not as if there is any expectation that this serialized state is gonna be consistent between nodes

kiitos··on If you are good at code review, you will be good at using AI agents
> But it's not exactly rewarding to add one more CRUD endpoint. It's a shit-ton of typing in multiple layers.

i don't disagree with you but if "adding one more CRUD endpoint" and similar rote tasks represent any significant amount of your engineering hours, especially in the context of business impact, then something is fundamentally broken in your team, engineering org, or company overall

time spent typing code into an editor is usually, hopefully!, approximately statistically 0% of overall engineering time

kiitos··on Cap'n Web: a new RPC system for browsers and web servers
mm, i think you're describing corba, not rpc in general
kiitos··on Configuration files are user interfaces
my mistake I think in using the term "language" as KSON isn't really a language in any normal definition of "language", it's really I guess a data serialization format, which is fully defined in terms of its (specified) grammar and syntax rules

i.e. until that "formal grammar" which is currently a comment in a Kotlin source file ;) becomes a versioned and reference-able spec that can be implemented by third-parties this is all a bit of a cart/horse dilemma i think maybe

kiitos··on Is Zig's new writer unsafe?
mmm, no, that's an explicitly incomplete list of informally-described observable behaviors that qualify as undefined -- which is fine and good! but quite far from a specification!
kiitos··on Dear GitHub: no YAML anchors, please
> and so I read the YAML specification

but there isn't a single YAML spec, there are at least 2 in common use: yaml 1.1, and 1.2, which have discrete specs and feature-sets. re: anchor stuff specifically, 1.1 supports merge keys whereas 1.2 explicitly does not, so that's one thing

and github actions does not actually specify which yaml spec/version it uses when parsing workflow yaml files

it's unfortunately just not the case that "YAML means something" that is well-defined in the sense that you mean here

kiitos··on If you are good at code review, you will be good at using AI agents
the time spent literally typing code into an editor is never the bottleneck in any competently-run project

if the act of writing code is something you consider a burden rather than a joy then my friend you are in the wrong profession

kiitos··on Is Zig's new writer unsafe?
curious, where is the definition of "undefined behavior" for rust specified?
kiitos··on Is Zig's new writer unsafe?
yup, he's also got a consistent history of aggressively disparaging and misinformed comments about go, fwiw
kiitos··on Is Zig's new writer unsafe?
> So how would the Decompress Reader be implemented correctly? Should it use its own buffer that is guaranteed to be large enough?

yes

> If so, how would it allocate that buffer?

as it sees fit. or, it can offer mechanisms for the caller to provide pre-allocated buffer(s). in any case the point is that this detail can't be the responsibility of the producer to satisfy, unless that requirement is specified somehow explicitly

in general the new zig io interfaces conflate behavior (read/write) with implementation (buffer size(s))

kiitos··on Configuration files are user interfaces
fun!

    name: 'Leonardo Bonacci'
    favorite_books:
      - title: Metaphysics
        author: Aristotle.
    favorite_numbers:
        - 1
        - 2
delete that `.` at the end of Aristotle and you get a totally structurally different result
kiitos··on Configuration files are user interfaces
KSON is a language defined by a grammar/spec, not any specific tool that implements that language, afaict? assuming so, where in that language spec do you define and control "warnings", in a way that other spec-compliant implementations would have equivalent behavior?
kiitos··on Configuration files are user interfaces
those formats aren't bijective with each other, right? so there's no way for you to say that foo.cue can be equivalently transformed to any foo.json or any foo.nginx or whatever representation, because those transformations are necessarily lossy, no?
kiitos··on ABC yanks Jimmy Kimmel’s show ‘indefinitely’ after threat from FCC chair
cool post, what are you trying to communicate with it? everything is the same, all positions are equivalent, there is no right or wrong?
kiitos··on Configuration files are user interfaces
Backwards-compatible means the new thing can handle the old things. Here JSON5 is backwards-compatible with JSON.

Forwards-compatible means the old thing can handle the new things. Here JSON is not forwards-compatible with JSON5.

kiitos··on Configuration files are user interfaces
if you're writing bash inside of yaml then something has gone wrong well before yaml entered the picture, this is a problem with e.g. azure not with the yaml format
kiitos··on Configuration files are user interfaces
two huge thumbs down for KSON
kiitos··on Humanely dealing with humungus crawlers
i was responding to something else, 100% my bad
kiitos··on Humanely dealing with humungus crawlers
sorry, yes, i think we are in agreement
← PreviousPage 3 of 28Next →