D5137: streamclone: new server config and some API changes for narrow stream clones

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Wed Oct 17 18:58:38 EDT 2018


martinvonz added inline comments.

INLINE COMMENTS

> bundle2.py:1691-1692
> +    # get the inlcudes and excludes
> +    includepats = kwargs[r'includepats']
> +    excludepats = kwargs[r'excludepats']
> +

I had to change these to `kwargs.get()` to get `test-http.t` and many others to pass. (I also fixed the typo in the comment above)

> config.txt:1851-1854
> +``stream-narrow-clones``
> +    Whether the server supports streaming narrow clones or not.
> +    (default: False)
> +

I removed this per indygreg's comment

> streamclone.py:549
> +    if includes or excludes:
> +        raise error.Abort(_("support for narrow stream clones is missing"))
> +

I changed this to "server does not support narrow stream clones" to match the error from bundle2.

Btw, why is it raised in two places? Is the one in bundle2 that actually happens? Maybe this should be a ProgrammingError then?

> test-narrow-clone-stream.t:37
> +  streaming all changes
> +  remote: abort: support for narrow stream clones is missing
> +  abort: pull failed on remote

I changed this to "server does not support narrow stream clones" to match the actual output (test was failing)

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D5137

To: pulkit, durin42, #hg-reviewers, martinvonz
Cc: martinvonz, indygreg, mercurial-devel


More information about the Mercurial-devel mailing list