guix-kreyren/guix/scripts
Christopher Baines 20c08a8a45
substitute: Rework connection error handling.
This is part of trying to reduce the interdependency of code within the
substitute module.

This commit addresses some of the error handling that was performed through
open-connection-for-uri/maybe. The new approach is to use
call-with-connection-error-handling, and wrap calls to http-multiple-get and
http-fetch with that procedure, which takes care of handling connection
errors.

I think this is even slightly more rigerous than the previous setup, because
this approach handles connection errors that occur when http-multiple-get
reconnects to a host.

* guix/scripts/substitute.scm (open-connection-for-uri/maybe): Transform in to
call-with-connection-error-handling.
(fetch-narinfos): Use call-with-connection-error-handling.
(process-query): Replace open-connection-for-uri/maybe with
open-connection-for-uri/cached.
(open-connection-for-uri/cached): Set a default timeout, matching the
behaviour in open-connection-for-uri/maybe.
(process-substitution): Use call-with-connection-error-handling.
2021-02-22 20:43:12 +00:00
..
container
git
import
system
archive.scm
authenticate.scm
build.scm
challenge.scm
container.scm
copy.scm
deploy.scm
describe.scm guix describe: 'display-profile-content' checks the right generation. 2021-02-05 23:15:36 +01:00
discover.scm
download.scm
edit.scm
environment.scm environment: Allow starting from existing profile. 2021-02-11 17:59:07 +08:00
gc.scm
git.scm
graph.scm
hash.scm
import.scm
install.scm
lint.scm
offload.scm
pack.scm
package.scm
perform-download.scm
processes.scm
publish.scm
pull.scm pull: Create the "${XDG_CONFIG_HOME}/guix" directory when needed. 2021-02-12 20:54:33 +08:00
refresh.scm
remove.scm
repl.scm
search.scm
show.scm
size.scm
substitute.scm substitute: Rework connection error handling. 2021-02-22 20:43:12 +00:00
system.scm scripts: system: Accept <image> records as input. 2021-02-17 10:57:02 +01:00
time-machine.scm
upgrade.scm
weather.scm