From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id uE9rD7dVrl/iHAAA0tVLHw (envelope-from ) for ; Fri, 13 Nov 2020 09:45:27 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id 4P5CC7dVrl/oBwAAB5/wlQ (envelope-from ) for ; Fri, 13 Nov 2020 09:45:27 +0000 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 F0C12940657 for ; Fri, 13 Nov 2020 09:45:26 +0000 (UTC) Received: from localhost ([::1]:48138 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kdVe1-0001t9-UF for larch@yhetil.org; Fri, 13 Nov 2020 04:45:25 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:53862) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kdVds-0001sk-Kj for guix-devel@gnu.org; Fri, 13 Nov 2020 04:45:16 -0500 Received: from relay3-d.mail.gandi.net ([217.70.183.195]:54229) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kdVdq-0000ZE-QA; Fri, 13 Nov 2020 04:45:16 -0500 X-Originating-IP: 90.92.160.122 Received: from bababa (lfbn-idf2-1-1094-122.w90-92.abo.wanadoo.fr [90.92.160.122]) (Authenticated sender: mail@ambrevar.xyz) by relay3-d.mail.gandi.net (Postfix) with ESMTPSA id E306C60007; Fri, 13 Nov 2020 09:45:11 +0000 (UTC) From: Pierre Neidhardt To: Ryan Prior , Ludovic =?utf-8?Q?Court=C3=A8s?= Subject: Re: Announcing emacs-guix-packaging In-Reply-To: References: Date: Fri, 13 Nov 2020 10:45:08 +0100 Message-ID: <87ft5dzj2z.fsf@ambrevar.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Received-SPF: pass client-ip=217.70.183.195; envelope-from=mail@ambrevar.xyz; helo=relay3-d.mail.gandi.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/11/13 04:41:39 X-ACL-Warn: Detected OS = Linux 3.11 and newer [fuzzy] X-Spam_score_int: 6 X-Spam_score: 0.6 X-Spam_bar: / X-Spam_report: (0.6 / 5.0 requ) BAYES_00=-1.9, FROM_SUSPICIOUS_NTLD=0.499, PDS_OTHER_BAD_TLD=1.999, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Development of GNU Guix and the GNU System distribution Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: "Guix-devel" X-Scanner: ns3122888.ip-94-23-21.eu Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-devel-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-devel-bounces@gnu.org X-Spam-Score: -0.61 X-TUID: 8wNHN7w0u+K1 --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi! On the one hand, I can only echo Ryan's experience, and I suppose the experience of most of us: emacs-guix has been a bit broken for a while now. I believe it suffers from 2 main issues: =2D Geiser is a strong dependency: everything depends from a well-working Geiser REPL. - Geiser 0.12 broke the REPL setup :( - Geiser chokes on large outputs, which happens on any Guix build. So you can't build anything with emacs-guix. =2D Emacs-Guix uses private parts of Guix if I'm not mistaken. Since these parts are prone to change, it breaks Emacs-Guix once in a while. Finally, it seems that Emacs-Guix is mostly unmaintained now: https://github.com/alezost/guix.el/issues/38#issuecomment-617718043 On the other hand, leveraging the actual Guix API is a saner approach than parsing the output. It's what I did in Nyxt: https://github.com/atlas-engineer/nyxt/blob/2-pre-release-4/libraries/ospam= a/ospama-guix.lisp It's fast, reliable, flexible, structured. > On the other hand, I am interested in building out a formal API for > tools to interface with Guix without having to depend on its internals > or parse the output of its CLI commands. This could be a Guile API, > although I picture json would be a better choice to support diverse > tooling. Guix already has a stable API that can be leveraged by any programming language thanks to the `guix repl` command. This is what I'm doing in Nyxt. > For one example of what I'd want the API for, in my `guix-packaging- > insert-input` command I need to get the list of available Guix packages, > and then for the selected package I need to find its scheme symbol. The > emacs-guix approach to those things is to reach into Guix internal data > structures and read out that data, which doesn't deliver results in > practice. Maybe emacs-guix does not do it well, but `fold-packages` works well for Nyxt in practice! > I opt instead to parse the output of the CLI command `guix > package -A ""` as a tsv, which works as long as Guix doesn't change its > output, but that's not guaranteed either. Indeed, I don't think this is the right approach :p Let me know what you think! Cheers! =2D-=20 Pierre Neidhardt https://ambrevar.xyz/ --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQFGBAEBCAAwFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAl+uVaQSHG1haWxAYW1i cmV2YXIueHl6AAoJEJvc9Jeku8x//2EIAIFR3k5Iq8oAox0lW0C9KWNlolQvlxnv isVUD5SampmvJ3tO4XLXPFn19HRAJhDTxCnUbdP+e7avSgD/YIkXP8midw948DUa v+Lm8lxqmRoGQF+lz9gXdOfDJpizPe0zLSfc0GWkQin3Q/CbLOs4bRAR+2LZZb/L IvV3IjkMrEfGQXE9AaoSiO5zYOTytjSEWTWpcyWXgm34tyCBXSmo4G3wxfHAl3sQ Zpy/qY/OifmuZZJoN4J1jRUxdczw0RnOAJuVuNHfwXsmXbPnvfsuuBhdg9vGokDP coZQvjUOUXfC1ipuPwaf2ywCAIwP82wKpvIa/I8bsTtNrDItNKWyR24= =4dve -----END PGP SIGNATURE----- --=-=-=--