git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: git-applymbox broken?

From
Linus Torvalds <torvalds@osdl.org>
Date
Jun 12, 2006, 19:10 UTC
Message-ID
<Pine.LNX.4.64.0606121204220.5498@g5.osdl.org>
In-Reply-To
<m13bea6w13.fsf@ebiederm.dsl.xmission.com>
On Mon, 12 Jun 2006, Eric W. Biederman wrote:
> 
> Below is an example of the kind of patch that inspired me to relax the
> rules on parsing in body headers (this comes from Andi Kleen quilt tree).
And this is wrong.

We should _not_ accept crappy patches, and then start guessing at what the person meant.

>From the very beginning of git, I tried to make it extremely clear that 

there is never any guessing going on. We don't use "heuristics" except as a pure optimization: ie a heuristic can have a _performance_ impact, but it must never EVER have semantic impact.

SCM's are not about guessing. They are about saving the _exact_ state that the user asked for. No "let's try to be nice", no gray areas.

If the new git-applymbox just takes random lines from the body of the email, and decides that they may be authorship information, then that is a BUG. The "From: " line in the middle of an email may well be about somebody having _discovered_ the bug, and we're quoting him as part of the explanation. It does NOT mean that it's about authorship.

So we should ONLY check for "From:" (and perhaps "Subject:" and "Date:") at the very top of the email body. NOWHERE ELSE.

The fact that somebody has a crappy quilt tree, and the fact that quilt is very much a "anything goes" kind of laissez faire system does not mean, and should NEVER mean that git becomes the same kind of mess of "let's do a best effort and try to guess what somebody means" kind of thing.

I check and edit my emails before I apply them, and I try to teach the people who send them manners and what the rules are. THAT is the way to handle this, not by having the tool itself become unreliable and random

		Linus
Previous: Eric W. BiedermanNext: Eric W. Biederman
Message 8 of 13 in “git-applymbox broken?”
  1. Linus TorvaldsJun 11, 2006
  2. Eric W. BiedermanJun 11, 2006
  3. Linus TorvaldsJun 12, 2006
  4. Eric W. BiedermanJun 12, 2006
  5. Ignore blank lines among this inbody headers.Eric W. Biederman, Jun 12, 2006
  6. Ignore blank lines among this inbody headersEric W. Biederman, Jun 12, 2006
  7. Eric W. BiedermanJun 12, 2006
  8. Linus TorvaldsJun 12, 2006
  9. Don't parse any headers in the real body of an email message.Eric W. Biederman, Jun 12, 2006
  10. Eric W. BiedermanJun 12, 2006
  11. Johannes SchindelinJun 12, 2006
  12. Randy.DunlapJun 12, 2006
  13. Ryan AndersonJun 13, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.