From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id SHZNNcCz+mFMFgEAgWs5BA (envelope-from ) for ; Wed, 02 Feb 2022 17:39:28 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id GG3QMcCz+mElPAEAauVa8A (envelope-from ) for ; Wed, 02 Feb 2022 17:39:28 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 7B5F6394DE for ; Wed, 2 Feb 2022 17:39:28 +0100 (CET) Received: from localhost ([::1]:56748 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nFIfH-000077-9c for larch@yhetil.org; Wed, 02 Feb 2022 11:39:27 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50570) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nFHgs-0007MI-CX for guix-patches@gnu.org; Wed, 02 Feb 2022 10:37:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:59212) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nFHgs-00063A-2q for guix-patches@gnu.org; Wed, 02 Feb 2022 10:37:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nFHgr-0005lL-QC for guix-patches@gnu.org; Wed, 02 Feb 2022 10:37:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#52555] [RFC PATCH v2 3/5] Add (guix eris). Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 02 Feb 2022 15:37:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52555 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: pukkamustard Cc: ~pukkamustard/eris@lists.sr.ht, 52555@debbugs.gnu.org Received: via spool by 52555-submit@debbugs.gnu.org id=B52555.164381622022144 (code B ref 52555); Wed, 02 Feb 2022 15:37:01 +0000 Received: (at 52555) by debbugs.gnu.org; 2 Feb 2022 15:37:00 +0000 Received: from localhost ([127.0.0.1]:53109 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFHgq-0005l5-GQ for submit@debbugs.gnu.org; Wed, 02 Feb 2022 10:37:00 -0500 Received: from andre.telenet-ops.be ([195.130.132.53]:35326) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nFHgo-0005ks-O9 for 52555@debbugs.gnu.org; Wed, 02 Feb 2022 10:36:59 -0500 Received: from ptr-bvsjgyhxw7psv60dyze.18120a2.ip6.access.telenet.be ([IPv6:2a02:1811:8c09:9d00:3c5f:2eff:feb0:ba5a]) by andre.telenet-ops.be with bizsmtp id qFcw2600R4UW6Th01FcweW; Wed, 02 Feb 2022 16:36:57 +0100 Message-ID: <26bc58741a60c972226cd47832b27de955e4a57a.camel@telenet.be> From: Maxime Devos Date: Wed, 02 Feb 2022 16:36:56 +0100 In-Reply-To: <86sft1h7wh.fsf@posteo.net> References: <20220125192201.7582-1-pukkamustard@posteo.net> <20220125192201.7582-4-pukkamustard@posteo.net> <0b977ae15a49b051c04922d234149a8e4762404f.camel@telenet.be> <86sft1h7wh.fsf@posteo.net> Content-Type: multipart/signed; micalg="pgp-sha512"; protocol="application/pgp-signature"; boundary="=-Ye3tASNbF2cSg/wmoG5a" User-Agent: Evolution 3.38.3-1 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1643816217; bh=0Lel4E0xIIF7zO0TlpU8F7P9LVPeRH9JSCNKMfBDEu0=; h=Subject:From:To:Cc:Date:In-Reply-To:References; b=a8Q+gJvXY8G2+ZN9IaAj/RUrZn5iv3AgGEH5i6nZndwnXV+J7iq31wfC5CmxTLTn7 f4yAI5kUtfdoy91JwIUhYC3XQSRMifc4GLf9zfsZo/WQCzoX8S/eSSY3kdWMMVcL4l J4kZZbOz6Pu3mVIKINe/mgoK1SXlTZRUJNwMHCyUp3nT9eOp/NFIe6zoo+mPR4X/8G taeVs7y4USILwrY1QtG0JgSyxweLFnp6lto9rqBwilkofdrcE9gMvLfybJ4meuDcx+ aGc0+Gum7xqqehUV7jvXAoLgAY0QP3mBLFabSGRMq/5SvNDKxKwGSvcmSSEYa7ub2c jxvf5nNtfqWFg== X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1643819968; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=0Lel4E0xIIF7zO0TlpU8F7P9LVPeRH9JSCNKMfBDEu0=; b=sVgwgUbsxuD9rFYa+h2ItWfBtlzNa2GjEHAa6oxMcD2KO+LT+wyQ76ncl/0ZupIeQ5kVmm dG+Du+csSofcfTIMsbv42BkC8pQf4MdFvXkixu0hMGN6XQegKt3as79XxFYLqDf8zVclJl KyssXO6YtDZkZmpbBjEJzfAiOBXjPPVMep1dSof4Am0kUkMltExEwjlAetJxT4JH+XQS5O 2dOjozSxINTahpxmoXSEBI0VKQDw5Q51oAyioLV37/ofdUrIjs9wgmkiUqWgL62wv5Uyd7 yVLt43yKMeF37SdEllbc0bbHbezADRHC4G85SX+CuZVzvgLJM5QGgfTorWTmIg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1643819968; a=rsa-sha256; cv=none; b=unpxwYKW+yGvZQfp281ZJm28YqB1c9GV4cSniATaBAvUxaT6CQ/mt1teuZ6JTjdkj4LyGL w6rfRJr2YEDqdWlUeDUDfWODDa5XX44V8EaHkjtwOKMNyufKenfv9poFTJ2tpCM+YD86m5 +eeUh90tyM7LfoaznowROagY4V4E5GjJKWl+Z5CKS9JEM02DULan3F3cJFSPVIhVXJf27g zl11HiDUT3qrf0uMtbkhYon58UZ4v63psNmTvjg60cfYGGjMc6vDbWmbmiaQY8gJogqUFJ 0tnze/51sHljR4+E365A1oWa40b+U1liDAzQ3BneCa7Ye1YtjUaIlaSIxhptNA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=telenet.be header.s=r22 header.b=a8Q+gJvX; dmarc=fail reason="SPF not aligned (relaxed)" header.from=telenet.be (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -5.23 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=telenet.be header.s=r22 header.b=a8Q+gJvX; dmarc=fail reason="SPF not aligned (relaxed)" header.from=telenet.be (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 7B5F6394DE X-Spam-Score: -5.23 X-Migadu-Scanner: scn0.migadu.com X-TUID: l3T6cny67hUC --=-Ye3tASNbF2cSg/wmoG5a Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable pukkamustard schreef op wo 02-02-2022 om 10:28 [+0000]: > > pukkamustard schreef op di 25-01-2022 om 19:21 [+0000]: > > > +(define (ipfs-daemon-alive?) > > > +=C2=A0 "Attempt to connect to the IPFS daemon. Returns #t if the > > > daemon is alive > > > +and #f else." > > > +=C2=A0 (with-exception-handler > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (const #f) > > > +=C2=A0=C2=A0=C2=A0 (lambda _ > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (let ((response _ > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (http-post (st= ring-append (%ipfs-base-url) > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 > > > "/api/v0/version")))) > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (equal? 200 (response-cod= e response)))) > > > +=C2=A0=C2=A0=C2=A0 #:unwind? #t)) > >=20 > > This should preferably only be catching exceptions indicating that > > the daemon is down (exceptions indicating 404s, or system-errors > > indicating network errors, ...). >=20 > Yes, I guess it could be checked a bit finer. But at the end if an > exception happens then the IPFS daemon is probably not reachable, > right? > If we don't care about the reason why it is not reachable then why > bother with catching finer grained exceptions? The exception could be caused by, say: * an unbound variable * wrong arity * type error * stack overflow * prompt tag does not exist in current environment * out of memory Except for the last one, these causes are all bugs and hence shouldn't be surpressed. Granted, this is a bit unlikely since this use of 'http-post' is very simple, but it's far from impossible for (web client) to have a bug. Greetings, Maxime. --=-Ye3tASNbF2cSg/wmoG5a Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYfqlGBccbWF4aW1lZGV2 b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7lMuAQCTlCl2Q5LRrRQiIKgiwuimw1Sm NXVCP9Pf/eOoQZMWAAD+NpY1trIo+TZLI+tmUcKBARROcYliOgUMS0RgLj1l3Qk= =sgcN -----END PGP SIGNATURE----- --=-Ye3tASNbF2cSg/wmoG5a--