Re: Can't see the forest for the trees - when reading file, only processing first line

2006-04-13 Thread bruno at modulix
News wrote: > Hi Everyone, > > > The attached code creates client connections to websphere queue managers > and then processes an inquiry against them. > > The program functions when it gets options from the command line. > > It also works when pulling the options from a file. > > My issue is

Re: Can't see the forest for the trees - when reading file, only processing first line

2006-04-13 Thread News
[EMAIL PROTECTED] wrote: > Suggest keeping it simple: > > def use_file(): > return open(options.filename).readlines() > > m > Very cool.. Didn't know you could do that. -- http://mail.python.org/mailman/listinfo/python-list

Re: Can't see the forest for the trees - when reading file, only processing first line

2006-04-13 Thread matt
Suggest keeping it simple: def use_file(): return open(options.filename).readlines() m News wrote: > Hi Everyone, > > > The attached code creates client connections to websphere queue managers > and then processes an inquiry against them. > > The program functions when it gets options from the

Re: Can't see the forest for the trees - when reading file, only processing first line

2006-04-13 Thread Heiko Wundram
Am Donnerstag 13 April 2006 19:12 schrieb News: > The use_file() function should be returning each file line. How do you think it should do that? There's a return line statement in the function which breaks function execution right after having read the first line. Rethink your logic... --- He

Can't see the forest for the trees - when reading file, only processing first line

2006-04-13 Thread News
Hi Everyone, The attached code creates client connections to websphere queue managers and then processes an inquiry against them. The program functions when it gets options from the command line. It also works when pulling the options from a file. My issue is that it only processes the first l