git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Nguyen Thai Ngoc Duy <pclouds@gmail.com>
To: Jeff King <peff@peff.net>
Cc: Junio C Hamano <gitster@pobox.com>, git <git@vger.kernel.org>
Subject: Re: [PATCH v2 3/3] {fetch,upload}-pack: allow --depth=0 for infinite depth
Date: Wed, 25 Aug 2010 08:12:06 +1000	[thread overview]
Message-ID: <AANLkTimqwXmRYVZLkYtGLd5=e1B0hKKePA0XzOYPrifd@mail.gmail.com> (raw)
In-Reply-To: <20100824135341.GA6457@coredump.intra.peff.net>

On Tue, Aug 24, 2010 at 11:53 PM, Jeff King <peff@peff.net> wrote:
> On Mon, Aug 23, 2010 at 10:08:24PM +1000, Nguyễn Thái Ngọc Duy wrote:
>
>> Users can do --depth=2147483648 for infinite depth now. It just looks
>> ugly. So make "0" special (i.e. infinite depth) at plumbing/protocol
>> level.
>
> What happens if I connect to an older server? Shouldn't "I understand
> depth=0 is infinite" be a server capability, and we hack around it by
> sending depth=2^32-1 when we have a modern client but an older server?

Older servers won't accept depth=0, dying with "Invalid deepen"
message. I don't really want to send a large number as a workaround,
it just does not feel safe. Users can either play around with
--depth=2^32-1, or upgrade servers.

And in case of modern server and old client, old fetch-pack would
never send "deepen 0", so it's safe too, at least for current
fetch-pack.
-- 
Duy

  parent reply	other threads:[~2010-08-24 22:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-23 12:08 [PATCH v2 1/3] clone: warn users --depth is ignored in local clones Nguyễn Thái Ngọc Duy
2010-08-23 12:08 ` [PATCH v2 2/3] fetch-pack: use args.shallow to detect shallow clone instead of args.depth Nguyễn Thái Ngọc Duy
2010-08-24 16:31   ` Junio C Hamano
2010-08-24 22:14     ` Nguyen Thai Ngoc Duy
2010-08-23 12:08 ` [PATCH v2 3/3] {fetch,upload}-pack: allow --depth=0 for infinite depth Nguyễn Thái Ngọc Duy
2010-08-24 13:53   ` Jeff King
2010-08-24 17:39     ` Junio C Hamano
2010-08-24 17:46       ` Jeff King
2010-08-24 22:12     ` Nguyen Thai Ngoc Duy [this message]
2010-08-24  5:28 ` [PATCH v2 1/3] clone: warn users --depth is ignored in local clones Jonathan Nieder
2010-08-24  5:52   ` Nguyen Thai Ngoc Duy

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='AANLkTimqwXmRYVZLkYtGLd5=e1B0hKKePA0XzOYPrifd@mail.gmail.com' \
    --to=pclouds@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).