Re: lock problem

2007-03-18 Thread Leo Kislov
On Mar 16, 3:08 pm, Ritesh Raj Sarraf <[EMAIL PROTECTED]> wrote: > Leo Kislov wrote: > > But you miss the fact that there is only one environment per process. > > Maybe there's a confusion. > The environment variable that I'm setting has noting to do with ldapsearch. I > use the environment variabl

Re: lock problem

2007-03-18 Thread Gabriel Genellina
En Fri, 16 Mar 2007 19:08:14 -0300, Ritesh Raj Sarraf <[EMAIL PROTECTED]> escribió: >> But you miss the fact that there is only one environment per process. > > Maybe there's a confusion. > The environment variable that I'm setting has noting to do with > ldapsearch. I > use the environment va

Re: lock problem

2007-03-17 Thread Ritesh Raj Sarraf
Leo Kislov wrote: > But you miss the fact that there is only one environment per process. Maybe there's a confusion. The environment variable that I'm setting has noting to do with ldapsearch. I use the environment variable as a filename to which ldapsearch can redirect its output. And that I do

Re: lock problem

2007-03-17 Thread Ritesh Raj Sarraf
Leo Kislov wrote: > But you miss the fact that there is only one environment per process. > Oh!! I think I get your point. There'd be only one __kabc_ldap environment variable to which all the threads would be overwriting. Hmmm!! Yes, you're correct. Thanks for pointing it out. Ritesh -- Rit

Re: lock problem

2007-03-17 Thread Gabriel Genellina
En Fri, 16 Mar 2007 04:40:27 -0300, Ritesh Raj Sarraf <[EMAIL PROTECTED]> escribió: > Leo Kislov wrote: > >> You're changing environmental variable __kabc_ldap that is shared >> between your threads. Environment is not designed for that kind of >> usage, it was designed for settings. Either use

Re: lock problem

2007-03-16 Thread Leo Kislov
On Mar 16, 12:40 am, Ritesh Raj Sarraf <[EMAIL PROTECTED]> wrote: > Leo Kislov wrote: > > You're changing environmental variable __kabc_ldap that is shared > > between your threads. Environment is not designed for that kind of > > usage, it was designed for settings. Either use an option to set > >

Re: lock problem

2007-03-16 Thread Ritesh Raj Sarraf
Leo Kislov wrote: > You're changing environmental variable __kabc_ldap that is shared > between your threads. Environment is not designed for that kind of > usage, it was designed for settings. Either use an option to set > output file or just redirect stdout. If the interface of ldapsearch is > s

Re: lock problem

2007-03-16 Thread Ritesh Raj Sarraf
Gabriel Genellina wrote: > En Thu, 15 Mar 2007 18:31:29 -0300, Ritesh Raj Sarraf <[EMAIL PROTECTED]> > escribió: > >> I'm not sure if there's something wrong in the code mentioned above or >> is it >> really a lock problem. > > Try to break

Re: lock problem

2007-03-15 Thread Leo Kislov
I'm not sure if there's something wrong in the code mentioned above or is it > really a lock problem. > > Can somebody please help about where I'm doing any mistake ? You're changing environmental variable __kabc_ldap that is shared between your threads. Environment is

Re: lock problem

2007-03-15 Thread Gabriel Genellina
En Thu, 15 Mar 2007 18:31:29 -0300, Ritesh Raj Sarraf <[EMAIL PROTECTED]> escribió: > I'm not sure if there's something wrong in the code mentioned above or > is it > really a lock problem. Try to break the code into smaller pieces to see what is wrong. It's too

lock problem

2007-03-15 Thread Ritesh Raj Sarraf
Hi, I think there is some lock problem. Let me show the code first import os import sys import string import tempfile import threading import Queue from time import sleep _hostname = None _username = None _password = None _ldapDataFile = None if _hostname is None or _username is None or