Re: [BangPypers] Reg : Python Scripting

2009-12-09 Thread Madhusudhan sunkara
may be you should redesign your program/logic , os.system call won't return without finishing On Wed, Dec 9, 2009 at 4:34 PM, murugadoss murugadoss2...@gmail.com wrote: Hello, I am writing a python script for executing my program. This is a thread program and on execution get the input

Re: [BangPypers] Reg : Python Scripting

2009-12-09 Thread Kushal Das
On Wed, Dec 9, 2009 at 4:34 PM, murugadoss murugadoss2...@gmail.com wrote: \ Sample Script: os.system(my program) child.sendline(input arguments) Use subprocess module. Kushal -- http://fedoraproject.org http://kushaldas.in ___ BangPypers mailing

Re: [BangPypers] Reg : Python Scripting

2009-12-09 Thread Roshan Mathews
On Wed, Dec 9, 2009 at 4:34 PM, murugadoss murugadoss2...@gmail.com wrote: But since the thread is waiting for input ( in a while loop ), the control is not coming to next line of the script. (ie: to input arguments line). Sample Script: os.system(my program) child.sendline(input arguments)

Re: [BangPypers] Request for py program to insert space between two characters and saved as text?

2009-12-09 Thread Praveen Kumar
Hi sorry as i did not find the attached file. Just write this script and save with space.py * import sys print ' '.join([e for e in open(sys.argv[1], 'r').read()])* and run with the same command as Brijith told. Thanks Praveen On Wed, Dec 9, 2009 at 12:35 PM, BR!j!TH briji...@gmail.com wrote:

Re: [BangPypers] Request for py program to insert space between two characters and saved as text?

2009-12-09 Thread Praveen Kumar
But again the issue raise with file format if you save that file with ascii format but you are reading it as unicode. Try to convert the file to unicode before using it in python. On Wed, Dec 9, 2009 at 5:23 PM, Praveen Kumar praveen.python.pl...@gmail.com wrote: Hi sorry as i did not find the