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

Re: [PATCH 0/7] fix inconsistent uses of the_repo in parse_object()'s call chain

From
Jeff King <peff@peff.net>
Date
Feb 1, 2020, 11:04 UTC
Message-ID
<20200201110401.GA1864948@coredump.intra.peff.net>
In-Reply-To
<CAHd-oW4WBc0AmcZwmOBNNMVQW=JZ-pVhXf8ebL9exgPp13VvOQ@mail.gmail.com>
On Sat, Feb 01, 2020 at 01:44:04AM -0300, Matheus Tavares Bernardino wrote:
Show 15 quoted lines
> > I don't think we're particularly interested in supporting multiple
> > unrelated repositories within the same process. While that would be
> > convenient for some cases (e.g., you have a million repositories and
> > want to look at all of their trees without creating a million
> > processes), I don't think it's a goal anyone is really working towards
> > with this "struct repository" layer.
> 
> Thanks for these explanations. One thing that left me thinking,
> though, is about changing the_hash_algo to r->hash_algo (not only in
> oid_to_hex()). I previously thought this would eventually be required
> for the hash transition. But if I understood your comment correctly,
> it might not be necessary since the submodule should always match the
> superproject hash. And, as you mentioned, supporting multiple
> unrelated repos [in a single process] is not one of the main goals, as
> well. So wouldn't keep using the_hash_algo be OK?

Yes, by the reasoning in my message, it wouldn't be a big problem. But I literally hadn't thought about it until writing that, so I may either be missing something, or there may be plans from other folks working on the hash transition that contradict that.

Even if we don't care too much about it for now, though, it still seems like a step in the right direction.

-Peff
Previous: Matheus Tavares Bernardino
Message 16 of 16 in “fix inconsistent uses of the_repo in parse_object()'s call chain”
  1. 0/7 fix inconsistent uses of the_repo in parse_object()'s call chainMatheus Tavares, Jan 30, 2020
  2. 1/7 diff: make diff_populate_filespec() honor its repo argumentMatheus Tavares, Jan 30, 2020
  3. 2/7 cache-tree: use given repo's hash_algo at verify_one()Matheus Tavares, Jan 30, 2020
  4. 3/7 pack-check: use given repo's hash_algo at verify_packfile()Matheus Tavares, Jan 30, 2020
  5. 4/7 streaming: allow open_istream() to handle any repoMatheus Tavares, Jan 30, 2020
  6. Junio C HamanoJan 31, 2020
  7. 5/7 sha1-file: pass git_hash_algo to write_object_file_prepare()Matheus Tavares, Jan 30, 2020
  8. Torsten BögershausenFeb 1, 2020
  9. Jeff KingFeb 1, 2020
  10. 6/7 sha1-file: pass git_hash_algo to hash_object_file()Matheus Tavares, Jan 30, 2020
  11. 7/7 sha1-file: allow check_object_signature() to handle any repoMatheus Tavares, Jan 30, 2020
  12. Junio C HamanoJan 30, 2020
  13. brian m. carlsonJan 30, 2020
  14. Jeff KingJan 31, 2020
  15. Matheus Tavares BernardinoFeb 1, 2020
  16. Jeff KingFeb 1, 2020

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.