os.getlogin() Error
Chris Angelico
rosuav at gmail.com
Thu May 4 18:31:15 EDT 2017
On Fri, May 5, 2017 at 8:18 AM, Wildman via Python-list
<python-list at python.org> wrote:
> I am using pkexec to restart so $SUDO_USER is not set. For some
> reason sudo, su and su-to-root will freeze the first instance of
> the program and not let it close until the second instance closes.
> I have tried every method I can find to launch them and pkexec
> is the only one that works correctly.
>
> Thanks for the reply.
Ah, okay. I wonder if you can do the same thing? Just before you
invoke pkexec, create an environment variable with the current user
credentials. Then pkexec back to yourself, and look in the
environment.
ChrisA
More information about the Python-list
mailing list