RE: Almost There - os.kill()

2007-09-24 Thread Delaney, Timothy (Tim)
Delaney, Timothy (Tim) wrote: > Nope - pretty sure that an earlier version of Python defaulted to a > radix of 0, but it appears to default to a radix of 10 in Python 2.5. > > In any case, I've submitted a bug report and suggested new text for > the documentation of int() to make it clear what ha

RE: Almost There - os.kill()

2007-09-24 Thread Delaney, Timothy (Tim)
Carsten Haese wrote: > On Mon, 2007-09-24 at 19:48 +0800, Delaney, Timothy (Tim) wrote: >> Always be careful with int() incase any of the values have a leading >> zero - check the documentation for int() carefully. > > Why would leading zeroes be a problem? > int("10") > 10 int("010")

RE: Almost There - os.kill()

2007-09-24 Thread Carsten Haese
On Mon, 2007-09-24 at 19:48 +0800, Delaney, Timothy (Tim) wrote: > Always be careful with int() incase any of the values have a leading > zero - check the documentation for int() carefully. Why would leading zeroes be a problem? >>> int("10") 10 >>> int("010") 10 >>> int("0010") 10 >>> int("00010

RE: Almost There - os.kill()

2007-09-24 Thread Carsten Haese
On Mon, 2007-09-24 at 12:40 +0100, Robert Rawlins - Think Blue wrote: > Woops, > > > > Spoke too soon, just wrapped them in int() and it works a charm :-D I'm glad that you figured it out for yourself. I'd like to suggest that you adjust your "give up and ask the list for help" threshold upwar

RE: Almost There - os.kill()

2007-09-24 Thread Delaney, Timothy (Tim)
2007 5:10 PM To: 'Robert Rawlins - Think Blue'; python-list@python.org Subject: RE: Almost There - os.kill() Woops, Spoke too soon, just wrapped them in int() and it works a charm :-D Rob From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] rg] On Behalf Of Robert Rawlins -

Re: Almost There - os.kill()

2007-09-24 Thread Carsten Haese
On Mon, 2007-09-24 at 12:23 +0100, Robert Rawlins - Think Blue wrote: > os.kill(pid, 15) > > TypeError: an integer is required > > > > Which would suggest its passing those arguments in as the wrong data > types to the kill command. What is the best way to convert these? Instead of giving

RE: Almost There - os.kill()

2007-09-24 Thread Robert Rawlins - Think Blue
Woops, Spoke too soon, just wrapped them in int() and it works a charm :-D Rob From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Rawlins - Think Blue Sent: 24 September 2007 12:23 To: python-list@python.org Subject: Almost There - os.kill() Hello Guys, Finall