GNU logs - #74949, boring messages


Message sent to bug-guix@HIDDEN:


X-Loop: help-debbugs@HIDDEN
Subject: bug#74949: guix describe crash if HOME is unset OR /etc/passwd is missing
Resent-From: Simon Josefsson <simon@HIDDEN>
Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
Resent-CC: bug-guix@HIDDEN
Resent-Date: Wed, 18 Dec 2024 17:26:01 +0000
Resent-Message-ID: <handler.74949.B.173454271427698 <at> debbugs.gnu.org>
Resent-Sender: help-debbugs@HIDDEN
X-GNU-PR-Message: report 74949
X-GNU-PR-Package: guix
X-GNU-PR-Keywords: 
To: 74949 <at> debbugs.gnu.org
X-Debbugs-Original-To: bug-guix@HIDDEN
Received: via spool by submit <at> debbugs.gnu.org id=B.173454271427698
          (code B ref -1); Wed, 18 Dec 2024 17:26:01 +0000
Received: (at submit) by debbugs.gnu.org; 18 Dec 2024 17:25:14 +0000
Received: from localhost ([127.0.0.1]:35813 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1tNxnN-0007C8-Pb
	for submit <at> debbugs.gnu.org; Wed, 18 Dec 2024 12:25:14 -0500
Received: from lists.gnu.org ([209.51.188.17]:52374)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <simon@HIDDEN>) id 1tNxnM-0007AV-3i
 for submit <at> debbugs.gnu.org; Wed, 18 Dec 2024 12:25:12 -0500
Received: from eggs.gnu.org ([2001:470:142:3::10])
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <simon@HIDDEN>)
 id 1tNxnK-0003M3-16
 for bug-guix@HIDDEN; Wed, 18 Dec 2024 12:25:11 -0500
Received: from uggla.sjd.se ([2001:9b1:8633::107])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <simon@HIDDEN>)
 id 1tNxnE-00084M-EH
 for bug-guix@HIDDEN; Wed, 18 Dec 2024 12:25:08 -0500
DKIM-Signature: v=1; a=ed25519-sha256; q=dns/txt; c=relaxed/relaxed;
 d=josefsson.org; s=ed2303; h=Content-Type:MIME-Version:Message-ID:Date:
 Subject:To:From:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID:
 Content-Description; bh=N3SALmvSUvU49ll2J5nHW059HczStiTsbXT5452tFkI=;
 t=1734542697; x=1735752297; b=6ZdXOrBOto8N6+wp9UK97WLjX2KpH6jhqqY512w7X1zpVdn
 R/NVLGN72Y0M4HUO20n+VD++JUTMqU8fiSug+Dw==;
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
 d=josefsson.org; s=rsa2303; h=Content-Type:MIME-Version:Message-ID:Date:
 Subject:To:From:Sender:Reply-To:Cc:Content-Transfer-Encoding:Content-ID:
 Content-Description; bh=N3SALmvSUvU49ll2J5nHW059HczStiTsbXT5452tFkI=;
 t=1734542697; x=1735752297; b=BENemjV2HRIJ8QJ0U/TNt4oQRY4xTI14dlTOzgACtw7aKmf
 /O3Q6mf07qftNFrdd1EP4RfbAEw3P6NL9hxPAsokHSXoMQC00sdepxMzplc0vz9iLd5LPoz6J2xsM
 5cDcrDFu36orAfHbl+u5yejoTsBV4boESlZzKL8hmW5LhLiIXhjHRoBaNcK9rXV0f+mPS0rJn1Fiy
 YF9ODVkh1Uo4IBrzYJfv06Z2OlCl3XntGHArptsYmox7oIiS0n4cit5j2Mo+RgVRj8ZYuGjAq9MA/
 6WcpgX80VmlZQCYBZhjIraE1casaEIQqwHJord19Njd1CygTU6GvRpSCjkzKNvB/+WD/5EltrssNq
 cHY3WQ4SF/gvqZNfzSxmCgcn6140q6HbShojYCyv9ZDyWbi9qGnJhkcLokWIEsRvrSQ/tS8rpGAsr
 Cz6Zp7NJf+sq1hgS/V+lp0c0;
Received: from h-178-174-130-130.a498.priv.bahnhof.se ([178.174.130.130]:48998
 helo=kaka) by uggla.sjd.se with esmtpsa (TLS1.3) tls
 TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95)
 (envelope-from <simon@HIDDEN>) id 1tNxn4-00Cmdu-Lp
 for bug-guix@HIDDEN; Wed, 18 Dec 2024 17:24:54 +0000
X-Hashcash: 1:23:241218:bug-guix@HIDDEN::GlyyRPFURdQU35ri:WErF
From: Simon Josefsson <simon@HIDDEN>
OpenPGP: id=B1D2BD1375BECB784CF4F8C4D73CF638C53C06BE;
 url=https://josefsson.org/key-20190320.txt
Date: Wed, 18 Dec 2024 18:25:00 +0100
Message-ID: <87pllokioj.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux)
MIME-Version: 1.0
Content-Type: multipart/signed; boundary="=-=-=";
 micalg=pgp-sha256; protocol="application/pgp-signature"
Received-SPF: pass client-ip=2001:9b1:8633::107;
 envelope-from=simon@HIDDEN; helo=uggla.sjd.se
X-Spam_score_int: -43
X-Spam_score: -4.4
X-Spam_bar: ----
X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_PASS=-0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: -1.4 (-)
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

--=-=-=
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

Hi

I get the backtrace below.  Setting either HOME to something, or adding
an entry to /etc/passwd for the running user, silences this.

I don't think it should fail like this, should it?

Is a reasonable behaviour to assume HOME means "/" when unset?

How to handle missing /etc/passwd entries probably depends on what the
code wants to use it for.

/Simon

jas@kaka:~/src/guix-container$ podman run --entrypoint /bin/sh -it registry=
.gitlab.com/debdistutils/guix/container:latest
sh-5.1# guix describe
Backtrace:
In ice-9/boot-9.scm:
   222:29 19 (map1 _)
   222:29 18 (map1 _)
   222:29 17 (map1 _)
   222:29 16 (map1 _)
   222:29 15 (map1 _)
   222:29 14 (map1 _)
   222:29 13 (map1 _)
   222:29 12 (map1 (((guix packages)) ((guix profiles)) ((guix #)) ?))
   222:17 11 (map1 (((guix profiles)) ((guix derivations)) ((# #)) ?))
  3327:17 10 (resolve-interface (guix profiles) #:select _ #:hide _ # ?)
In ice-9/threads.scm:
    390:8  9 (_ _)
In ice-9/boot-9.scm:
  3253:13  8 (_)
In ice-9/threads.scm:
    390:8  7 (_ _)
In ice-9/boot-9.scm:
  3544:20  6 (_)
   2836:4  5 (save-module-excursion #<procedure 7fe582a23b10 at ice-?>)
  3564:26  4 (_)
In unknown file:
           3 (primitive-load-path "guix/profiles" #<procedure 7fe582?>)
In guix/profiles.scm:
  2388:23  2 (_)
In guix/utils.scm:
  1071:48  1 (xdg-directory _ "/.config" #:ensure? _)
In unknown file:
           0 (getpw 0)

ERROR: In procedure getpw:
In procedure getpw: entry not found
sh-5.1# export HOME=3D/
sh-5.1# guix describe
  guix 790c9ff
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: 790c9ffe596e3deabf175e030adee5fb706aa981
sh-5.1# exit
jas@kaka:~/src/guix-container$ podman run --entrypoint /bin/sh -it registry=
.gitlab.com/debdistutils/guix/container:latest
sh-5.1# guix describe
Backtrace:
In ice-9/boot-9.scm:
   222:29 19 (map1 _)
   222:29 18 (map1 _)
   222:29 17 (map1 _)
   222:29 16 (map1 _)
   222:29 15 (map1 _)
   222:29 14 (map1 _)
   222:29 13 (map1 _)
   222:29 12 (map1 (((guix packages)) ((guix profiles)) ((guix #)) ?))
   222:17 11 (map1 (((guix profiles)) ((guix derivations)) ((# #)) ?))
  3327:17 10 (resolve-interface (guix profiles) #:select _ #:hide _ # ?)
In ice-9/threads.scm:
    390:8  9 (_ _)
In ice-9/boot-9.scm:
  3253:13  8 (_)
In ice-9/threads.scm:
    390:8  7 (_ _)
In ice-9/boot-9.scm:
  3544:20  6 (_)
   2836:4  5 (save-module-excursion #<procedure 7fac35694b10 at ice-?>)
  3564:26  4 (_)
In unknown file:
           3 (primitive-load-path "guix/profiles" #<procedure 7fac35?>)
In guix/profiles.scm:
  2388:23  2 (_)
In guix/utils.scm:
  1071:48  1 (xdg-directory _ "/.config" #:ensure? _)
In unknown file:
           0 (getpw 0)

ERROR: In procedure getpw:
In procedure getpw: entry not found
sh-5.1# echo 'root:x:0:0:root:/root:/bin/bash' > /etc/passwd
sh-5.1# guix describe
  guix 790c9ff
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: 790c9ffe596e3deabf175e030adee5fb706aa981
sh-5.1#=20

--=-=-=
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iIoEARYIADIWIQSjzJyHC50xCrrUzy9RcisI/kdFogUCZ2MFbBQcc2ltb25Aam9z
ZWZzc29uLm9yZwAKCRBRcisI/kdFoic9AP0Z7iO3HtsuJPRH4v3xjYWiBj3v98Qq
TxoGeIAa57A16QEA64OY+7LWlvA4JXryX0VPu239KnreeEUbTW0RWzSU6gc=
=yOvL
-----END PGP SIGNATURE-----
--=-=-=--




Message sent:


Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
X-Mailer: MIME-tools 5.505 (Entity 5.505)
Content-Type: text/plain; charset=utf-8
X-Loop: help-debbugs@HIDDEN
From: help-debbugs@HIDDEN (GNU bug Tracking System)
To: Simon Josefsson <simon@HIDDEN>
Subject: bug#74949: Acknowledgement (guix describe crash if HOME is unset
 OR /etc/passwd is missing)
Message-ID: <handler.74949.B.173454271427698.ack <at> debbugs.gnu.org>
References: <87pllokioj.fsf@HIDDEN>
X-Gnu-PR-Message: ack 74949
X-Gnu-PR-Package: guix
Reply-To: 74949 <at> debbugs.gnu.org
Date: Wed, 18 Dec 2024 17:26:02 +0000

Thank you for filing a new bug report with debbugs.gnu.org.

This is an automatically generated reply to let you know your message
has been received.

Your message is being forwarded to the package maintainers and other
interested parties for their attention; they will reply in due course.

Your message has been sent to the package maintainer(s):
 bug-guix@HIDDEN

If you wish to submit further information on this problem, please
send it to 74949 <at> debbugs.gnu.org.

Please do not send mail to help-debbugs@HIDDEN unless you wish
to report a problem with the Bug-tracking system.

--=20
74949: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D74949
GNU Bug Tracking System
Contact help-debbugs@HIDDEN with problems



Last modified: Sun, 12 Jan 2025 05:45:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.