Re: [Tutor] pwd lib probs

2008-08-18 Thread John Fouhy
2008/8/19 dave selby <[EMAIL PROTECTED]>: > Hi all, > > I am using the pwd lib where I am codeing things like ... > > gid = pwd.getpwnam(apache2_user)[3] > > where as I would like to code it as ... > > gid = pwd.getpwnam(apache2_user)[pwd.pw_gid] > > but I get > > gid = pwd.getpwnam(apache2_user)[p

[Tutor] pwd lib probs

2008-08-18 Thread dave selby
Hi all, I am using the pwd lib where I am codeing things like ... gid = pwd.getpwnam(apache2_user)[3] where as I would like to code it as ... gid = pwd.getpwnam(apache2_user)[pwd.pw_gid] but I get gid = pwd.getpwnam(apache2_user)[pwd.pw_gid] AttributeError: 'module' object has no attribute 'p