Re: Having problems accepting parameters to a function

2007-05-01 Thread Gabriel Genellina
En Tue, 01 May 2007 18:42:18 -0300, rh0dium <[EMAIL PROTECTED]> escribió: > Let me expand a bit more - I am working on a threading class and I > want to be able to push on the Queue a list of args. If you run the > following program - I am failing to understand how to push items onto > the queu

Re: Having problems accepting parameters to a function

2007-05-01 Thread 7stud
kwargs is not a built in name--it's a made up name used in the docs.Would you expect this function to work: def somefunc(x=10, y=20): print a The best way to figure out a feature of a programming language that you don't understand is not in the middle of some complex program. Instead, yo

Re: Having problems accepting parameters to a function

2007-05-01 Thread rh0dium
Thanks to all who helped!! Let me expand a bit more - I am working on a threading class and I want to be able to push on the Queue a list of args. If you run the following program - I am failing to understand how to push items onto the queue in a manner so that func2 recognizes them as kwargs not

Re: Having problems accepting parameters to a function

2007-05-01 Thread 7stud
On May 1, 11:06 am, 7stud <[EMAIL PROTECTED]> wrote: > > You might consider redefining func() so that you don't have to do the > unpack--repack... When you define a function like this: def func(**keywordargs): print keywordargs the function expects to receive arguments in the form: func(a="

Re: Having problems accepting parameters to a function

2007-05-01 Thread 7stud
On May 1, 10:38 am, rh0dium <[EMAIL PROTECTED]> wrote: > Hi Experts!! > > I am trying to get the following little snippet to push my data to the > function func(). What I would expect to happen is it to print out the > contents of a and loglevel. But it's not working. Can someone please > help m

Re: Having problems accepting parameters to a function

2007-05-01 Thread Stargaming
rh0dium schrieb: > Hi Experts!! > > I am trying to get the following little snippet to push my data to the > function func(). What I would expect to happen is it to print out the > contents of a and loglevel. But it's not working. Can someone please > help me out. > > --- >

Having problems accepting parameters to a function

2007-05-01 Thread rh0dium
Hi Experts!! I am trying to get the following little snippet to push my data to the function func(). What I would expect to happen is it to print out the contents of a and loglevel. But it's not working. Can someone please help me out. --- #!/usr/bin/env python import rand