Live data from Hacker News

Grit: Rewriting Git in Rust with agents

blog.gitbutler.com

111–120 of 318 posts

Re: Grit: Rewriting Git in Rust with agents

#111
post #106
post #96

Earlier quoted context omitted.

Writing fn sum(a: u8, b: u8) { a + b } Doesn't infringe upon copyright period, because there's no creative element in that work. Imagine a more substantial example though. Perhaps you have a test that checks that some file written in a binary format is correct, and gives names (creative elements) to each field of the format that it prints when you mess up the field, and has comments describing why the bytes are laid…

> Doesn't infringe upon copyright period, because there's no creative element in that work. There's likely a threshold at some point. It's helpful to look at a minima and then continue from there though. I'm curious if there's case law that supports your assertions here?

For that assertion in particular I believe I'm practically parroting a ruling by the district court in Oracle vs Google about some extremely simple Java functions that Oracle claimed Google copied. Though I can't say I checked to make sure I'm remembering right.

Re: Grit: Rewriting Git in Rust with agents

#112
post #98
post #94

Earlier quoted context omitted.

This is the exact thing I'm not sure about. See https://news.ycombinator.com/item?id=48470397 where I posit a simpler question: if a `test_sum()` function is copyrighted, does writing a `sum(a, b)` function infringe on the copyright of the software product that `test_sum()` is a part of. I'd say no. There's another part of the GPL that applies here: > A compilation of a covered work with other separate and independen…

test_sum is assumedly relatively trivial. So as a lay person I’d expect some sort of obviousness test to apply. Like so much of the stuff in the Google/Oracle lawsuit. But if you take all the individual tests used to test git as a whole, that seems far more unique. Seems like at that point you’re really having to duplicate the actual git internals, and that seems like it should be covered.

> test_sum is assumedly relatively trivial. So as a lay person I’d expect some sort of obviousness test to apply. Like so much of the stuff in the Google/Oracle lawsuit.

Feel free to extrapolate to the threshold where it's not and at that point apply.

> you’re really having to duplicate the actual git internals

Copyright covers the expression, not the method. So the Rust function:

    fn sum(a: u8, b: u8) {
        a + b
    }
is distinct from the C function:

    int sum(int a, int b) 
    {
        return a + b;
    }

Re: Grit: Rewriting Git in Rust with agents

#113
post #46

Grit was the name of a _Ruby_ implementation of git way back when: https://github.com/mojombo/grit/ . I believe it's actually what GitHub was built on then.

I started the project as Gust, but felt like Grit was such a better name. I asked Tom if I could boot the name back up again because I always liked it and he said it was fine.

Also, I worked on the Ruby Grit pretty extensively during the early days of GitHub, so hopefully I earned the right to carry on the mantle. :)

Re: Grit: Rewriting Git in Rust with agents

#114

I’m all for memory safety and such but honestly what’s the use case for this? Showing off agentic development? In 10+ years git has never failed on a memory overflow or else. Sometimes software is “good as is” and I’m pretty confident git classifies as such. I’ve also never really hit the limitations of git, even with teams of 20+ developers and lots of binary artefacts. You got to really stretch git limitations, in…

How else could they launder the git license and set themselves up for a bait and switch later down the line?

Re: Grit: Rewriting Git in Rust with agents

#115

What’s the long term strategy for this code base? Does the author expect community code contribution or just bug reports or maybe just test contributions?

I'm happy to take contributions if you want to throw some tokens at it. Bug reports would be amazing, since I haven't tested it for real very much (enough to know you can do basics).

I want to get it to the point where we can replace fork/exec'ing to an unknown Git binary or having said binary be an external dependency for GitButler. The networking stuff (push/fetch) is currently an external dep for both GitButler and Jujutsu (and pretty much every other Git-based tool in the world). I'm pretty sure I can get the project good enough at these networking ops (including all the hairy credential stuff) to be able to not need those fork/exec calls.

Re: Grit: Rewriting Git in Rust with agents

#117
post #99

Earlier quoted context omitted.

I addressed this in the post, but Git has no linkable library and never has. If you want to do even something small, you need to fork/exec a process and communicate with it via stdin/out. Or completely reimplement it and all of the edge cases - for example, reading even one object can be either loose (easy) or in a packfile (much more difficult). Reading a reference (what SHA does a branch point to) can be in a loose…

But libgit2 exists, right? It may not have 100% feature parity with git, but that's a linkable library that gives you a lot of functionality when working with git repos.

the author of this post (whom you were responding to) made `libgit`, the library that preceded `libgit2`, and contributed to libgit2 a long time ago as well. Here he is in 2010 writing about libgit2: https://github.blog/news-insights/libgit2-a-git-linkable-lib...

Re: Grit: Rewriting Git in Rust with agents

#118
post #111
post #106

Earlier quoted context omitted.

> Doesn't infringe upon copyright period, because there's no creative element in that work. There's likely a threshold at some point. It's helpful to look at a minima and then continue from there though. I'm curious if there's case law that supports your assertions here?

For that assertion in particular I believe I'm practically parroting a ruling by the district court in Oracle vs Google about some extremely simple Java functions that Oracle claimed Google copied. Though I can't say I checked to make sure I'm remembering right.

You're recalling it right, but there's a nice quote from Judge Alsup in that case that talks about this exact situation:

> “So long as the specific code used to implement a method is different, anyone is free under the Copyright Act to write his or her own code to carry out exactly the same function or specification...”

Here given that this is rust and the original expression is C, the implementations cannot be the same by definition.

Re: Grit: Rewriting Git in Rust with agents

#120
post #109

Earlier quoted context omitted.

The test suite could test aspects of the architecture/design of the codebase that are not necessary for interoperability and constitute novel expression of a piece of software in a way that is not at all language specific.

By definition a test suite is about testing interoperability with the test suite. An HTTP test suite should likely test for whether response code 418 is implemented a particular way and while humorous it would still be an interop test no?

No, the git test suite is about testing the git codebase. If you want something like that, you need a conformance suite, which does not exist for git.
Post reply on HN