#11169 NORM Not Tri: os.getlogin does fail in terminal
Zarro Boogs per Child
bugtracker at laptop.org
Tue Aug 30 00:18:25 EDT 2011
#11169: os.getlogin does fail in terminal
------------------------------------+---------------------------------------
Reporter: erikos | Owner:
Type: defect | Status: new
Priority: normal | Milestone: Not Triaged
Component: not assigned | Version: Development build as of this date
Resolution: | Keywords:
Next_action: never set | Verified: 0
Deployment_affected: | Blockedby:
Blocking: |
------------------------------------+---------------------------------------
Changes (by Quozl):
* version: not specified => Development build as of this date
Comment:
os.getlogin() is defined as ''Return the name of the user logged in on the
controlling terminal of the process.'' Since there is no user logged in,
either on serial port or in X server context, the behaviour is undefined.
pwd.getpwuid(os.getuid())[0] is more correct. Perhaps fedpkg should use
it? ''fedpkg clone fedpkg'' didn't work for me, but the change was
obvious.
A workaround is to ssh into the host, or use a virtual console.
I don't think we should login the olpc user unless there's some other good
reason ... like was it always done this way?
--
Ticket URL: <http://dev.laptop.org/ticket/11169#comment:1>
One Laptop Per Child <http://laptop.org/>
OLPC bug tracking system
More information about the Bugs
mailing list