Can't set attribute?!

2009-09-01 Thread dolgion ch
Hi there, i'm new to Python, and i don't understand why following exception occurs in this code: class NETRPCGateway(RPCGateway): """NETRPC Implementation. """ def __init__(self, host, port): self.host = host self.port = port super(NETRPCGateway, self).__init_

Re: Can't set attribute?!

2009-09-01 Thread alex23
dolgion ch wrote: > the NETRPCGateway attribute self.db can't be set? why not? i've tried > changing the RPCSession login function > to set the variable like this as well: > > self.gateway.db = db > > which doesn't work either, same exception. > > any suggestions? The problem is this line in

Re: Can't set attribute?!

2009-09-01 Thread dolgion ch
alex23 u were right with ur suspicion about the RPCGateway, i hadn't seen that there were attributes with the names db, uid, and password already set. I resolved the issue by simply giving the attributes different names :P the problem with the slots wasn't going to occur since i was talking about

Re: Why does this group have so much spam?

2009-09-01 Thread Steven D'Aprano
On Tue, 01 Sep 2009 19:33:47 -0400, Terry Reedy wrote: > David wrote: >> >> I'm not saying that criminals shouldn't being prosecuted, but we are >> talking of something else: creating and environment that discurages >> criminals, because present enviroment is pretty wild and criminals have >> a bi

Re: Overriding iadd for dictionary like objects

2009-09-01 Thread Aahz
In article <7f82416a-53be-41b3-9503-1492454cc...@upsg2000gro.googlegroups.com>, RunThePun wrote: >On Sep 1, 3:00=A0am, a...@pythoncraft.com (Aahz) wrote: >> In article .com>, >> RunThePun =A0 wrote: >>>On Aug 30, 10:33=3DA0pm, a...@pythoncraft.com (Aahz) wrote: In article ups=3D >>>.com>, >>

Re: Is behavior of += intentional for int?

2009-09-01 Thread Steven D'Aprano
On Tue, 01 Sep 2009 16:43:06 -0700, Carl Banks wrote: >> Numbers are immutable by nature (math). The number 3.14 remains 3.14 >> whatever you try to do with it. What you call an immutable number is in >> fact a container that contains a number. > > I wouldn't agree with that terminology or logic.

using queue

2009-09-01 Thread Tim Arnold
Hi, I've been using the threading module with each thread as a key in a dictionary. I've been reading about Queues though and it looks like that's what I should be using instead. Just checking here to see if I'm on the right path. The code I have currently compiles a bunch of chapters in a book

Re: Every thing on a database

2009-09-01 Thread Gabriel Genellina
En Tue, 01 Sep 2009 23:16:29 -0300, zelegolas escribió: I guess it's may be a strange idea that I will explain: I really like python but I have one thing that I don't like: Every packages are defined with folder tree. To deploy an application it's not really clean. It's why I thought about

Re: Why does this group have so much spam?

2009-09-01 Thread r
On Sep 1, 10:16 pm, Steven D'Aprano wrote: (snip) > That's a different kettle of fish. You don't do anybody any harm by > paying for Internet access for your neighbours (and anyone driving down > the street with a laptop and wi-fi). naughty, naughty! somebody's been wardriving! ;-) > Took me t

Re: Every thing on a database

2009-09-01 Thread Steven D'Aprano
On Tue, 01 Sep 2009 19:16:29 -0700, zelegolas wrote: > I really like python but I have one thing that I don't like: Every > packages are defined with folder tree. To deploy an application it's not > really clean. > > It's why I thought about "Is that possible to put everything that I need > for m

Re: Daemon process

2009-09-01 Thread Gabriel Genellina
En Wed, 02 Sep 2009 00:57:02 -0300, Shan escribió: I have XML RPC Server listening on a port. This XML RPC Server works fine when i run it as foreground process. All the clients are able to connect with the XML RPC Server. But when i run it as daemon(not using &. I am doing it in python way o

Daemon process

2009-09-01 Thread Shan
I have XML RPC Server listening on a port. This XML RPC Server works fine when i run it as foreground process. All the clients are able to connect with the XML RPC Server. But when i run it as daemon(not using &. I am doing it in python way only), then no clients are able to connect with the Server

Re: Python-list Digest, Vol 72, Issue 10

2009-09-01 Thread Raji Seetharaman
Thanks MRAB. Now it works. -- http://mail.python.org/mailman/listinfo/python-list

Re: Seeking a python code browser

2009-09-01 Thread Daniel Fetchinson
> Is there any recommendation for a python code browser (aka xref) tool. > I am a Source Navigator user, but seems like its python support is > flaky. Unless you can help me with that...which is my preferred way. Check out code investigator: http://codeinvestigator.googlepages.com/main HTH, Dani

Re: Why does this group have so much spam?

2009-09-01 Thread Terry Reedy
Steven D'Aprano wrote: I have read more that one person advocating leaving one's wi-fi base open for anyone to use as the 'neighborly' thing to do. That's a different kettle of fish. You don't do anybody any harm by paying for Internet access for your neighbours (and anyone driving down the

Problem with multiprocessing

2009-09-01 Thread tleeuwenb...@gmail.com
I have a problem using multiprocessing in a simple way. I created a file, testmp.py, with the following contents: --- import multiprocessing as mp p = mp.Pool(5) def f(x): return x * x print map(f, [1,2,3,4,5]) print p.map(f, [1,2,3,4,5]) -

Re: An assessment of the Unicode standard

2009-09-01 Thread Gabriel Genellina
En Tue, 01 Sep 2009 19:49:57 -0300, r escribió: On Sep 1, 1:52 pm, Hyuga wrote: (snip) I'd say don't feel the troll, but too late for that I guess.   The only trolls in this thread are you and the others who breaks into MY THREAD just for the knee-jerk reaction of troll calling! Even though

<    1   2