is there enough information?

Jeff Schwab jeff at schwabcenter.com
Tue Feb 26 12:37:16 EST 2008


castironpi at gmail.com wrote:
> On Feb 26, 10:59 am, Preston  Landers <pland... at gmail.com> wrote:
>> On Feb 26, 1:45 am, castiro... at gmail.com wrote:
>>
>>> Two options occurred to me, which the first showed up in the earlier
>>> extremely skeletal and cryptic post:
>> Perhaps you would be more likely to get the kind of help you seem to
>> want
>> if you refrained from posting "cryptic and skeletal" messages. The
>> fact that many
>> other people have pointed this out to you as of late would tend to
>> suggest
>> you are trolling, i.e. intentionally trying to foster miscommunication
>> and threads
>> that do nothing to advance anyones understanding.
>>
>> And regarding your other recent post about trying to find a "solution"
>> to the "problem"
>> of immutable types...  Due to the above reasons you are unlikely to
>> influence the
>> design of the core language with half-baked stream of consciousness
>> ramblings. These
>> belong in your LiveJournal, not in c.l.python.
>>
>> If you have a problem you need help with, please read this entire
>> document about 3 times
>> before posting anything else:
>>
>> http://catb.org/~esr/faqs/smart-questions.html
>>
>> Specifically this:
>>
>> http://catb.org/~esr/faqs/smart-questions.html#beprecise
>>
>> and this:
>>
>> http://catb.org/~esr/faqs/smart-questions.html#goal
> 
> Ugh, very well.  You call for an explanation.
> 
> Back home, the original post would be interesting, so I wrote it.
> Whatever reactions other people have to them is information that is
> unavailable to me.  I don't know you.  I'm rather irked by a
> proportion of posts, but for my part, it's hard to get me to point a
> finger.
> 
> I am not a troll.  I want a sustainable, healthy, productive,
> educational, informative relationship with frequenters of c.l.p, the
> Python community at large, and anyone who has anything non-negative to
> contribute.  If you are wanting to see how I react to hostility, just
> ask.  I'll fake it for you, but only for a second at a time.

Wow.  I sure hope I don't come across like castiron does here.

> Now, what help is it that you believe I seem to want?  All I asked for
> was, ideas.

It's a little difficult for me to interpret your code, partly because I 
am nbt very familiar with Python's support for concurrency.  But what 
are you trying to a achieve?

You mentioned:  "I recently ran into a case (* would that be helpful to 
describe here?) where thread1 had to do something, thread2 had to do 
something after that, and thread1 had to wait for that, then do 
something else, and thread2 again had to wait before starting the first 
thing again."

This is ordinarily called a Producer-Consumer model.  It is often 
implemented using semaphores.  Googling "python semaphore" turns up this 
documentation:

http://www.python.org/doc/lib/semaphore-objects.html

That page, in turn, links to an example of the proper use of semaphores 
in Python.  Does that help?



More information about the Python-list mailing list