public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Laszlo Ersek" <lersek@redhat.com>
To: Vladimir Olovyannikov <vladimir.olovyannikov@broadcom.com>,
	devel@edk2.groups.io
Cc: Samer El-Haj-Mahmoud <Samer.El-Haj-Mahmoud@arm.com>,
	Zhichao Gao <zhichao.gao@intel.com>,
	Maciej Rabeda <maciej.rabeda@linux.intel.com>,
	Jiaxin Wu <jiaxin.wu@intel.com>, Siyuan Fu <siyuan.fu@intel.com>,
	Ray Ni <ray.ni@intel.com>, Liming Gao <liming.gao@intel.com>,
	Nd <nd@arm.com>
Subject: Re: [edk2-devel] [PATCH v3 1/1] ShellPkg/DynamicCommand: add HttpDynamicCommand
Date: Fri, 24 Jul 2020 17:09:29 +0200	[thread overview]
Message-ID: <20cc1951-cd4e-a9d5-a24a-96f273002bed@redhat.com> (raw)
In-Reply-To: <8de76fe2aa9ca0f8ab45fe8245428453@mail.gmail.com>

On 07/23/20 19:18, Vladimir Olovyannikov wrote:


>>> One suggestion: if the download fails for some reason, but the local
>>> file creation succeeded, then upon exit, the local file should be
>>> deleted. Otherwise an incomplete (possibly zero size) file is left in
>>> the filesystem.

> I was thinking about this.
> Sometimes, an error file returned by HTTP server (say, on 404 or 503) has
> more information than just 404, 503, etc.
> That was the only reason I do not delete it.
> I still return error code to the caller, so the caller can read it (maybe,
> to provide more information to the user), and/or delete it right away.
> What do you think?

Seems unusual to me; at least I'm not used to it with "wget". I seem to
remember that, whenever I get a 404 or 503 with wget, I don't have to
clean up after wget.

With a graphical web browser, things are different, in that case,
rendering the textual (HTML etc) response can be helpful.

If you decide to keep the local files in such cases (i.e., on failure),
I suggest documenting that fact in the built-in help text.

Thanks!
Laszlo


  reply	other threads:[~2020-07-24 15:09 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-13 18:31 [PATCH v3 1/1] ShellPkg/DynamicCommand: add HttpDynamicCommand Vladimir Olovyannikov
2020-07-15 12:55 ` [edk2-devel] " Laszlo Ersek
2020-07-15 12:58   ` Laszlo Ersek
2020-07-15 17:09     ` Vladimir Olovyannikov
2020-07-16 12:19       ` Laszlo Ersek
2020-07-16 15:26         ` Samer El-Haj-Mahmoud
2020-07-16 17:14           ` Vladimir Olovyannikov
2020-07-16 17:07         ` Vladimir Olovyannikov
2020-07-22 19:37 ` Laszlo Ersek
2020-07-22 19:40   ` Laszlo Ersek
2020-07-23 13:30 ` Laszlo Ersek
2020-07-23 17:20   ` Vladimir Olovyannikov
2020-07-23 14:54 ` Laszlo Ersek
2020-07-23 15:02   ` Laszlo Ersek
2020-07-23 17:18     ` Vladimir Olovyannikov
2020-07-24 15:09       ` Laszlo Ersek [this message]
2020-07-24 17:50         ` Vladimir Olovyannikov

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-list 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=20cc1951-cd4e-a9d5-a24a-96f273002bed@redhat.com \
    --to=devel@edk2.groups.io \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox