Almost There - os.kill()

Carsten Haese carsten at uniqsys.com
Mon Sep 24 07:43:03 EDT 2007


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 you the fish, I'll give you a fishing rod. Use
inspection, experimentation, and the online documentation to answer the
following questions:

1) What type is the argument currently?
2) What type does the os.kill function expect?
3) How can you convert an object of type 1 to an object of type 2?

-- 
Carsten Haese
http://informixdb.sourceforge.net





More information about the Python-list mailing list