all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Tobias Geerinckx-Rice <me@tobias.gr>
To: 28262@debbugs.gnu.org
Subject: [bug#28262] [PATCH] Handle the same HTTP redirects everywhere.
Date: Mon, 28 Aug 2017 15:52:06 +0200	[thread overview]
Message-ID: <92edb6ea-1ba3-4fe2-d64e-ebf487c0bbb9@tobias.gr> (raw)
In-Reply-To: <20170828134610.30984-1-me@tobias.gr>

Tobias Geerinckx-Rice wrote on 28/08/17 at 15:46:
> diff --git a/guix/http-client.scm b/guix/http-client.scm
> index 3c5441c38..8db332093 100644
> --- a/guix/http-client.scm
> +++ b/guix/http-client.scm
> @@ -259,7 +260,10 @@ Raise an '&http-get-error' condition if downloading fails."
>            ((200)
>             (values data (response-content-length resp)))
>            ((301                                   ; moved permanently
> -            302)                                  ; found (redirection)
> +            302                                   ; found (redirection)
> +            303                                   ; see also
> +            307                                   ; temporary redirect
> +            308)                                  ; permanent redirect

s/redirect$/redirection/

> diff --git a/guix/scripts/lint.scm b/guix/scripts/lint.scm
> index aceafc674..b27732d39 100644
> --- a/guix/scripts/lint.scm
> +++ b/guix/scripts/lint.scm
> @@ -411,7 +412,11 @@ for connections to complete; when TIMEOUT is #f, wait as long as needed."
>                     (close-connection port))))
>  
>               (case (response-code response)
> -               ((301 302 307)
> +               ((301                    ; moved permanently
> +                 302                    ; found (redirection)
> +                 303                    ; see also
> +                 307                    ; temporary redirect
> +                 308)                   ; permanent redirect
>                  (let ((location (response-location response)))
>                    (if (or (not location) (member location visited))
>                        (values 'http-response response)

Dittums.

Kind regards,

T G-R

  reply	other threads:[~2017-08-28 13:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-28 13:46 [bug#28262] [PATCH] Handle the same HTTP redirects everywhere Tobias Geerinckx-Rice
2017-08-28 13:52 ` Tobias Geerinckx-Rice [this message]
2017-08-31 13:10 ` Ludovic Courtès
2017-09-05 16:21   ` bug#28262: " Tobias Geerinckx-Rice
2017-09-07  9:43     ` [bug#28262] " Ludovic Courtès

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

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

  git send-email \
    --in-reply-to=92edb6ea-1ba3-4fe2-d64e-ebf487c0bbb9@tobias.gr \
    --to=me@tobias.gr \
    --cc=28262@debbugs.gnu.org \
    /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 external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.