GNU bug report logs - #35047
"Running the Test Suite" root user

Previous Next

Package: guix;

Reported by: mikadoZero <mikadozero <at> yandex.com>

Date: Sat, 30 Mar 2019 12:50:02 UTC

Severity: normal

To reply to this bug, email your comments to 35047 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#35047; Package guix. (Sat, 30 Mar 2019 12:50:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to mikadoZero <mikadozero <at> yandex.com>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sat, 30 Mar 2019 12:50:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: mikadoZero <mikadozero <at> yandex.com>
To: bug-guix <at> gnu.org
Subject: "Running the Test Suite" root user
Date: Sat, 30 Mar 2019 08:47:56 -0400
Looking at "2.3 Running the Test Suite" of the manual it does not
mention that tests should be run as a non root user.

The test `tests/pack` fails when `make check` is run as a root user.  It
does not fail when run as a non root user.  I found this example by
running `make check TESTS="tests/pack.scm"`.  Is this an issue for many
tests?

I can prepare a patch for the relevant part (parts if this also applies
to `make check-system` as well) in "2.3 Running the Test Suite" of the
manual.

Should `make check-system` also be run as a non root user to avoid
failing tests?

Is there a section in the manual that explains why tests should not be
run as a root user which I can just refer to in the patch?  If not could
anyone provide an explanation which I could include in the patch?




Information forwarded to bug-guix <at> gnu.org:
bug#35047; Package guix. (Sat, 30 Mar 2019 13:51:01 GMT) Full text and rfc822 format available.

Message #8 received at 35047 <at> debbugs.gnu.org (full text, mbox):

From: Tobias Geerinckx-Rice <me <at> tobias.gr>
To: mikadoZero <mikadozero <at> yandex.com>
Cc: 35047 <at> debbugs.gnu.org
Subject: Re: bug#35047: "Running the Test Suite" root user
Date: Sat, 30 Mar 2019 14:50:35 +0100
[Message part 1 (text/plain, inline)]
mikadoZero,

mikadoZero wrote:
> Looking at "2.3 Running the Test Suite" of the manual it does 
> not
> mention that tests should be run as a non root user.

I guess this is one of those (Unix-)cultural knowledge things: it 
wouldn't even occur to me to build or test anything as root unless 
explicitly asked to do so :-)

> The test `tests/pack` fails when `make check` is run as a root 
> user.  It
> does not fail when run as a non root user.  I found this example 
> by
> running `make check TESTS="tests/pack.scm"`.  Is this an issue 
> for many
> tests?
>
> I can prepare a patch for the relevant part (parts if this also 
> applies
> to `make check-system` as well) in "2.3 Running the Test Suite" 
> of the
> manual.

Thanks for the offer!  I think adding yet another gotcha to the 
manual should be a last resort, though.  Many people still miss 
them and get into trouble (and on to IRC).

Could we, in order of preference:

- make these tests pass even when run as root?  (I guess not?)
- skip them and add ‘n tests not run as root’ to the final tally?
- refuse to even start the test suite as root?

What ‘root’ means here will depend on why these tests are failing.

Kind regards,

T G-R
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#35047; Package guix. (Sat, 30 Mar 2019 15:32:01 GMT) Full text and rfc822 format available.

Message #11 received at 35047 <at> debbugs.gnu.org (full text, mbox):

From: mikadoZero <mikadozero <at> yandex.com>
To: Tobias Geerinckx-Rice <me <at> tobias.gr>
Cc: 35047 <at> debbugs.gnu.org
Subject: Re: bug#35047: "Running the Test Suite" root user
Date: Sat, 30 Mar 2019 11:30:52 -0400
Tobias Geerinckx-Rice writes:

> mikadoZero,
>
> mikadoZero wrote:
>> Looking at "2.3 Running the Test Suite" of the manual it does not
>> mention that tests should be run as a non root user.
>
> I guess this is one of those (Unix-)cultural knowledge things: it
> wouldn't even occur to me to build or test anything as root unless
> explicitly asked to do so :-)
>
>> The test `tests/pack` fails when `make check` is run as a root user.
>> It
>> does not fail when run as a non root user.  I found this example by
>> running `make check TESTS="tests/pack.scm"`.  Is this an issue for
>> many
>> tests?
>>
>> I can prepare a patch for the relevant part (parts if this also
>> applies
>> to `make check-system` as well) in "2.3 Running the Test Suite" of
>> the
>> manual.
>
> Thanks for the offer!  I think adding yet another gotcha to the manual
> should be a last resort, though.  Many people still miss them and get
> into trouble (and on to IRC).
>
> Could we, in order of preference:
>
> - make these tests pass even when run as root?  (I guess not?)
> - skip them and add ‘n tests not run as root’ to the final tally?
> - refuse to even start the test suite as root?
>
> What ‘root’ means here will depend on why these tests are failing.
>
> Kind regards,
>
> T G-R

Preventing the issue instead of warning of it in the manual sounds like
a better solution to me.




This bug report was last modified 6 years and 74 days ago.

Previous Next


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