Skip to content

Unify pkt-line error handling and refactor smart-http

Josh Steadmon git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v3 Latest4 patches 8 repliesIn review

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4pack-protocol.txt: accept error packets in any contextDocumentation/technical/pack-protocol.txt builtin/archive.c connect.c +3 more+17 -187 replies
2/4remote-curl: refactor smart-http discoveryremote-curl.c+59 -340 replies
3/4remote-curl: tighten "version 2" check for smart-httpremote-curl.c+1 -10 replies
4/4lib-httpd, t5551: check server-side HTTP errorst/lib-httpd.sh t/lib-httpd/apache.conf t/lib-httpd/error-smart-http.sh +1 more+13 -00 replies

Reviews trailers per patch

None of the 4 patches has a Reviewed-by or Acked-by.

PatchJosh Steadmon
1/4
2/4Helped-by
3/4
4/4

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/4] Unify pkt-line error handling and refactor smart-http

This is a reroll of js/smart-http-detect-remote-error that also includes a fixed version of ms/proto-err-packet-anywhere [1].

The first patch clarifies the use of ERR messages in the pkt-line protocol and unifies error handling in pkt-line.c

The second patch refactors smart-http discovery in remote-curl.c. Among other improvements, it makes more use of the pkt-line functions, which allows us to catch remote errors that were previously ignored.

The third patch makes the version check in remote-curl more strict.

The final patch adds a test to verify that the fix in patch #2 does actually catch remote HTTP errors.

[1]: https://public-inbox.org/git/[email protected]/

Jeff King (2):
remote-curl: refactor smart-http discovery
remote-curl: tighten "version 2" check for smart-http

Josh Steadmon (1):
lib-httpd, t5551: check server-side HTTP errors

Masaya Suzuki (1):
pack-protocol.txt: accept error packets in any context

 Documentation/technical/pack-protocol.txt | 20 ++---
 builtin/archive.c                         |  2 -
 connect.c                                 |  3 -
 fetch-pack.c                              |  2 -
 pkt-line.c                                |  4 +
 remote-curl.c                             | 93 ++++++++++++++---------
 t/lib-httpd.sh                            |  1 +
 t/lib-httpd/apache.conf                   |  4 +
 t/lib-httpd/error-smart-http.sh           |  3 +
 t/t5551-http-fetch-smart.sh               |  5 ++
 t/t5703-upload-pack-ref-in-want.sh        |  4 +-
 11 files changed, 89 insertions(+), 52 deletions(-)
 create mode 100644 t/lib-httpd/error-smart-http.sh
Signature · 1 line
2.20.0.rc2.403.gdbc3b29805-goog