From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: guix system: error: service 'ssh-daemon' requires 'networking', which is undefined Date: Thu, 21 Jul 2016 15:00:41 +0200 Message-ID: <87oa5rm9hi.fsf@gnu.org> References: <874m7qzvyx.fsf@gnu.org> <0329ad9f3fc879d5b76e3d9bf895d75d@tobias.gr> <87wpkhlrwi.fsf@gnu.org> 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]:45059) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bQDaq-00085Y-7T for guix-devel@gnu.org; Thu, 21 Jul 2016 09:00:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bQDam-0001Y9-Bx for guix-devel@gnu.org; Thu, 21 Jul 2016 09:00:48 -0400 In-Reply-To: ("Jan \=\?utf-8\?B\?U3luw6HEjWVrIidz\?\= message of "Thu, 21 Jul 2016 08:30:16 +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: Jan =?utf-8?B?U3luw6HEjWVr?= Cc: guix-devel Jan Syn=C3=A1=C4=8Dek skribis: > On Tue, Jul 19, 2016 at 2:43 PM, Ludovic Court=C3=A8s wrot= e: >> I improved the message along these lines in commit >> 2c2ec261a8d3c37e5147038f47ad24c57cde4134, let me know what you think. >> >> To be more concrete about other improvements, here=E2=80=99s what should= be >> feasible (but needs to be discussed to see whether it=E2=80=99s actually >> helpful): >> >> 1. Display the location of the Shepherd service definition: >> >> gnu/services/ssh.scm:160:4: 'ssh-daemon' requires 'networking'=E2= =80=A6 >> >> Trivial to implement, but the downside is that the user doesn=E2=80= =99t >> really care about this file. >> >> 2. Same, but also show some sort of a stack trace (but not an actual >> Scheme stack trace) showing where this Shepherd service comes from: >> >> gnu/services/ssh.scm:160:4: 'ssh-daemon' requires 'networking'=E2= =80=A6 >> gnu/services/ssh.scm:117:30: =E2=80=A6 in extension of service 's= hepherd' >> gnu/services/ssh.scm:228:2: =E2=80=A6 while folding service 'lsh= =E2=80=99 instantiated here >> >> The problem is that, currently, we=E2=80=99d get the location of the >> (service =E2=80=A6) form, which is in the =E2=80=98lsh-service=E2= =80=99 procedure, in >> gnu/services/ssh.scm. >> >> It may be hard to come up with intelligible messages, and there=E2= =80=99s a >> risk that showing too many lines of messages would be >> counterproductive. >> >> Thoughts? Just to be clear, the message we now have is: service 'ssh-daemon' requires 'networking', which is not provided by any = service > From a regular user's point of view, this still misses the point, > which I originally attempted to make. I suggest an error message like > this: > > 'ssh-daemon' requires 'networking', try adding > 'static-networking-service' or 'dhcp-client-service' to system > services > > Or something like that. The point is, make it clear that "requires > networking" means adding at least one service to the operating > system's services and make at least one suggestion. Definitely a step > forward to user friendliness. So I think you=E2=80=99re saying that, in addition to the error message, yo= u=E2=80=99d like suggestions. I like the idea. However, in this specific case, I=E2=80=99m not sure how = to achieve it: =E2=80=98guix system=E2=80=99 doesn=E2=80=99t know about all th= e Shepherd services that can possibly exist, so it cannot tell you that the =E2=80=98networking= =E2=80=99 is provided if you add =E2=80=98dhcp-client-service=E2=80=99 or whatnot to you= r config file. I understand these are not details one cares about as a user, at least at first glance. But this limits what we can do. Thanks, Ludo=E2=80=99.