From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: In need for a simple "join build container" Date: Wed, 07 Jun 2017 14:30:28 +0200 Message-ID: <87shjc3rq3.fsf@gnu.org> References: <5936902D.5010502@crazy-compilers.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:37268) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dIa6d-0002UX-GI for guix-devel@gnu.org; Wed, 07 Jun 2017 08:30:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dIa6a-00043w-E8 for guix-devel@gnu.org; Wed, 07 Jun 2017 08:30:35 -0400 In-Reply-To: (Roel Janssen's message of "Tue, 06 Jun 2017 16:16:48 +0200") 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: Roel Janssen Cc: guix-devel Heya, Roel Janssen skribis: > Hartmut Goebel writes: > >> Hi, >> >> I find myself debugging some package test-cases quite often. This is >> *very* time-consuming, esp. if compiling the source takes several minute= s. >> >> So what I need is something to drop me into an interactive shell if the >> build fails. >> >> At the moment for these cases I try setting of an environment (see my >> other post just a few minutes ago). But this setup is quite complicated >> (so I wrote a wrapper-shell-script) and error-prone. And I assume, >> others packagers will need this, too. >> >> My ideal solution would be something like >> >> guix build --shell-on-failure mypackage >> >> Should I open a bug-report for this? > > I would find this really useful as I usually do the manual steps: > guix build -K > cd > bash > . environment_variables > cd > > Which is suboptimal because then you're not the build user in an > isolated environment. Did you see the suggestions we recently added to the manual? https://www.gnu.org/software/guix/manual/html_node/Debugging-Build-Failur= es.html The instructions are reasonable IMO. The proposed =E2=80=98--shell-on-failure=E2=80=99 could automate this thoug= h, and I agree it=E2=80=99d be nice. Technically it could be surprisingly difficult= to implement, for instance because the daemon doesn=E2=80=99t communicate in a machine-readable way the name of the failed build directory, and also because the directory name =E2=80=9Coutside=E2=80=9D might differ from the = directory name =E2=80=9Cinside=E2=80=9D (/data/tmp/guix-build-foo.drv-7 vs /tmp/guix-= build-foo.drv-0). Ludo=E2=80=99.