From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christopher Baines Subject: Re: 02/02: services: Add Gitolite. Date: Sun, 30 Sep 2018 11:28:14 +0100 Message-ID: <87d0sv7001.fsf@cbaines.net> References: <20180928200104.10056.60968@vcs0.savannah.gnu.org> <20180928200105.E0B4F20476@vcs0.savannah.gnu.org> <871s9b69mg.fsf@netris.org> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:32872) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1g6Yxd-00072s-Jm for guix-devel@gnu.org; Sun, 30 Sep 2018 06:28:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1g6Yxa-0001CY-EG for guix-devel@gnu.org; Sun, 30 Sep 2018 06:28:25 -0400 Received: from mira.cbaines.net ([2a01:7e00::f03c:91ff:fe69:8da9]:41420) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1g6YxY-0001Bp-QT for guix-devel@gnu.org; Sun, 30 Sep 2018 06:28:22 -0400 In-reply-to: <871s9b69mg.fsf@netris.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Mark H Weaver Cc: guix-devel@gnu.org --=-=-= Content-Type: text/plain Mark H Weaver writes: > Hi Christopher, > > mail@cbaines.net (Christopher Baines) writes: > >> cbaines pushed a commit to branch master >> in repository guix. >> >> commit 258a6d944ed891fa92fa87a16731e5dfe0bac477 >> Author: Christopher Baines >> Date: Fri Jul 13 20:39:46 2018 +0100 >> >> services: Add Gitolite. >> >> * gnu/services/version-control.scm (, >> ): New record types. >> (gitolite-accounts, gitolite-activation): New procedures. >> (gitolite-service-type): New variables. >> * gnu/tests/version-control.scm (%gitolite-test-admin-keypair, %gitolite-os, >> %test-gitolite): New variables. >> (run-gitolite-test): New procedure. >> * doc/guix.texi (Version Control): Document the gitolite service. > > This commit has a flaw which broke evaluations on Hydra, so I reverted > it for now. > >> +(define-gexp-compiler (gitolite-rc-file-compiler >> + (file ) system target) >> + (match file >> + (($ umask git-config-keys roles enable) >> + (apply text-file* "gitolite.rc" >> + `("%RC = (\n" >> + " UMASK => " ,(format #f "~4,'0o" umask) ",\n" > > The problem is here, in the call to 'format'. Guile has two variants of > the 'format' procedure: a very simple one which is always available > (also known as 'simple-format'), and a much more complex and featureful > variant in (ice-9 format). In the code above, you are assuming that > (ice-9 format) has been loaded, but you have not arranged for that to > happen. During the Hydra evaluation, this led to the following error: > > --8<---------------cut here---------------start------------->8--- > 0 (simple-format #f "~4,'0o" 63) > > ERROR: In procedure simple-format: > In procedure simple-format: FORMAT: Unsupported format option ~4 - use (ice-9 format) instead > --8<---------------cut here---------------end--------------->8--- Thanks for looking at this Mark, do you know where I can find out what Hydra is doing when it encounters this error? I tried looking around the web interface, but the latest evaluation I could find was from 2017 apparently. > I guess that the fix will involve 'with-imported-modules'. > Could you take a look? Sure. The confusing thing to me here is that this code works when using the service, including the system test (at least when I run it locally). Also, as far as I understand, even though the code is within a gexp-compiler, it doesn't even involve the store, as the call to format happens before the g-expression is generated. It sounds to me like adding #:use-modules (ice-9 format) to (gnu services version-control) would fix this, but I'll wait until I can reproduce the failure before re-adding the service. Thanks, Chris --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAluwpT5fFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9XerrA//Xlc0Gu8esNsrEoHy2LeV8MwC/4hnw9BNbKfYpmS8PytS/nZcnJBlmKFm UsNaEBZlrmW26Dfdx0vAQmKu74Q/n8yZokeRIb+zJnMSf74PkMkYnNtk/RQGy1Hh Vy73S7150u5T1SnBijfm0O7nj+tlJ3XZ7UPrw9MFbjevRD8bjKrOXD/+9unNtQag PFs4a6gUrZ8omOW1/X6GAfH1LzenmngTcvj6oxCLCSbcTfd08Eu3GkrVhesQ1HwI FN2QXJjH8O8OOV0d2FSjTh9P58tMHv+OjmENHtN27971UvsgI+islNh3znkn1IBQ 2rIBaZE3E4xnycuos4r6qujUF0ErrrRo1qpgwqFRFT1CE1xabQe6gKAa9omNFEwF QLEV0WwM2857tl+/slQZu8EYXJQUrzhNoP9QLiUfqi6OWt1Bv7bv7CYxN5TgOxN8 Wjr5ts2v0JPTiDgZcUWF2DzXo4Matk9MHGJ8nv83+a8rPcNIdFJQrdJ59ZtP+/Mk nCHAbRSlJVbYKdMXDhBqBl0cHTnan3YtYfAHMgH1673D7cMK8DDayCmwfW1yJ0kz 1qRdgkwCFZZs2K9Hmk92O+X+dInlbQ6z9WvmwP11EJUAEIqj243XSsVD+V0xhEec 1fTq4/e2mdjtAa2wvFGXuDXp/BfudYpeZ8FF7wu1/9ong4b49ZY= =O/EE -----END PGP SIGNATURE----- --=-=-=--