please, help with python 3.1

Steven D'Aprano steve-REMOVE-THIS at cybersource.com.au
Tue Aug 3 11:07:29 CEST 2010


Hello Alan,


I'm sorry, I can't see the code you say you posted. I can't see ANY of 
your posts, only the replies from Chris Rebert. 

Are you using Google Groups to post? If so, many people here will have 
difficulty seeing your posts, as Google Groups is notorious for allowing 
spammers, and in self-defence many mailing lists and newsgroups just 
ignore anything from Google Groups.

Looking at the message Chris forwarded:

  [quote]
  I am using for a task 'find /' expecting this to last longer, usually
  much longer than 5 sec. If you run the code I sent in python 2.6, it
  will stop after 5 sec and print messages. If you run the same code in
  python3 (and if your task last more than 5 sec as expected, otherwise
  replace "cmd = 'find /'" with something suitable), python3 alarm
  doesn't work and the job is not stopped after 5 sec, taking minutes to
  finish.
  [end quote]


I'm sorry, but I can't make heads or tails of that. At the very least, 
you need to explain what code you are using, and what the problem is. 
What do you mean "python3 alarm doesn't work"? What alarm? What do you 
mean it doesn't work? Just saying "it doesn't work" is pointless.

Is the problem that your code runs in seconds under Python 2.6 and takes 
minutes under Python 3.1? Are you sure you are using 3.1 and not 3.0? 3.0 
is VERY slow and should be avoided.

We may need to see your code, and some sample data, in order to have any 
hope of helping you.



Regards,


Steven.


On Tue, 03 Aug 2010 00:28:04 -0700, Chris Rebert wrote:

> ---------- Forwarded message ---------- From: Alan
> <alanwilter at gmail.com>
> Date: Tue, Aug 3, 2010 at 12:25 AM
> Subject: Re: please, help with python 3.1 To: Chris Rebert
> <clp2 at rebertia.com>
> 
> Sorry,
> I will explain. I am using for a task 'find /' expecting this to last
> longer, usually much longer than 5 sec. If you run the code I sent in
> python 2.6, it will stop after 5 sec and print messages.
> If you run the same code in python3 (and if your task last more than 5
> sec as expected, otherwise replace "cmd = 'find /'" with something
> suitable), python3 alarm doesn't work and the job is not stopped after 5
> sec, taking minutes to finish.
> I hope it may help you to help me.
> Thanks,
> Alan
> 
> On Tue, Aug 3, 2010 at 08:11, Chris Rebert <clp2 at rebertia.com> wrote:
>>
>> On Mon, Aug 2, 2010 at 11:35 PM, Alan <alanwilter at gmail.com> wrote:
>> > Hello List,
>> > Please, can someone at least try this code below in python 3 and
>> > report me back whether it works or not? Because for me this code
>> > works in python 2.6 but not with python 3.1. Thanks!
>>
>> Please specify *in exactly what way* the code is not working. Is an
>> exception being thrown? Then include the full traceback. Is the
>> behavior not what you expected/intended? Then say what it's doing vs.
>> what you want it to do.
>>
>> Cheers,
>> Chris
>> --
>> Getting Debugging Help 101: Don't just say "there's a problem". Say
>> what the problem is.
>> http://blog.rebertia.com



-- 
Steven



More information about the Python-list mailing list