This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author steven.daprano
Recipients amoss, steven.daprano, xtreak
Date 2018-09-27.12:40:20
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1538052020.19.0.545547206417.issue34709@psf.upfronthosting.co.za>
In-reply-to
Content
Versions 3.7 and below are all in feature-freeze, so this change could only apply to 3.8 and above.

I don't know if this feature is desirable or not.

If it is (sometimes?) desirable, my guess is that it would be undesirable to use SUDO_USER *unless* the effective user ID was 0. (Don't check for the name "root", that's only a convention.) In pseudocode:

    names = ('LOGNAME', 'USER', 'LNAME', 'USERNAME')
    if effective user ID == 0:
        names = ('SUDO_USER',) + names
    for name in names:
        ...


Also needs documentation and tests.
History
Date User Action Args
2018-09-27 12:40:20steven.dapranosetrecipients: + steven.daprano, xtreak, amoss
2018-09-27 12:40:20steven.dapranosetmessageid: <1538052020.19.0.545547206417.issue34709@psf.upfronthosting.co.za>
2018-09-27 12:40:20steven.dapranolinkissue34709 messages
2018-09-27 12:40:20steven.dapranocreate