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

Re: [PATCH] fix simple deepening of a repo

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 25, 2009, 06:33 UTC
Message-ID
<7vy6p8pfm1.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20090825061248.GG1033@spearce.org>
"Shawn O. Pearce" <spearce@spearce.org> writes:
Show 5 quoted lines
> The client knows the *name* of the ref, but not the SHA-1 the ref is
> currently valued at.  Thus when the client knows it wants a certain
> ref by name, it needs to send a "want " line to the server that would
> give it whatever that ref currently points at.  Unfortunately since we
> have not obtained that value yet, we are stuck.

That could be something you can fix in the out-of-band procedure Gerrit uses (you let the client learn both name and value offline, and then the client uses that value on "want" line).

However, even if we limit the discussion to Gerrit, you would need an updated client that can be called with the out-of-band information (i.e. "we know that changes/88/4488/2 points at X, so use X when requesting") when talking with such an updated server.

So I think that expand-refs is a much nicer general solution than just "server side is configured to hide but still allow certain refs", and client updates cannot be avoided.

And again, 
> The problem with this is servers which are sending this expand-refs
> tag have hidden certain namespaces from older clients.  Those names
> can't be seen by older git clients, unless the user does an upgrade.

I do not think "generally hidden, but if you need to know you are allowed to peek" is much of a problem. You do not do that for regular refs, only for "on-demand-as-needed" type things. If we are going to make extensive use of notes on commits to give richer annotations, I suspect notes hierarchy could be hidden by default in a similar way.

Previous: Shawn O. PearceNext: Shawn O. Pearce
Message 14 of 22 in “git fetch --depth=* broken?”
  1. Nicolas PitreAug 22, 2009
  2. fix simple deepening of a repoNicolas Pitre, Aug 24, 2009
  3. Junio C HamanoAug 24, 2009
  4. Nicolas PitreAug 24, 2009
  5. Johan HerlandAug 24, 2009
  6. Junio C HamanoAug 24, 2009
  7. Daniel BarkalowAug 24, 2009
  8. Julian PhillipsAug 24, 2009
  9. Nicolas PitreAug 25, 2009
  10. Shawn O. PearceAug 25, 2009
  11. Sverre RabbelierAug 25, 2009
  12. Junio C HamanoAug 25, 2009
  13. Shawn O. PearceAug 25, 2009
  14. Junio C HamanoAug 25, 2009
  15. Shawn O. PearceAug 25, 2009
  16. Shawn O. PearceAug 26, 2009
  17. Johannes SixtAug 26, 2009
  18. Shawn O. PearceAug 26, 2009
  19. Junio C HamanoAug 26, 2009
  20. Shawn O. PearceAug 26, 2009
  21. upload-pack: expand capability advertises additional refsShawn O. Pearce, Aug 28, 2009
  22. Junio C HamanoAug 28, 2009

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.