Ask your own question, for FREE!
MIT 6.00 Intro Computer Science (OCW) 18 Online
OpenStudy (anonymous):

Why does Python crash when I run PS5 (Spring 2011)? When I run the test everything is ok. I've done everything except part 4 (user-specified triggers) and it says that it should work by now.

OpenStudy (anonymous):

Anyone?

OpenStudy (anonymous):

you didn't post your code. the question you asked probably wasn't what you intended. if it should work it should work so something is wrong and if you want us to de-bug or troubleshoot it for you, you need to post your code and ask more specific questions. i imagine that anyone reading this forum that isn't posting a similar question does not have a problem with their ps5 solutions

OpenStudy (anonymous):

@David Can you provide more information by adding some code Just copy your code and paste it here like `YOUR_CODE_HERE` Then we'll be able to help you

OpenStudy (anonymous):

pls use a code pasting site like: http://dpaste.com http://pastebin.com http://codepad.org select Python for syntax hi-lighting

OpenStudy (anonymous):

Sorry for the delay but wasn't able to post it sooner. http://dpaste.com/794541/

OpenStudy (anonymous):

what is not happening? I got two news stories as soon as i ran it then it slept and polled and slept and ........... seems to be working

OpenStudy (anonymous):

kinda cool

OpenStudy (anonymous):

i can change the triggers in the main_thread function and get different stories

OpenStudy (anonymous):

I just completed the last part (Part 4 - http://dpaste.com/795168/ ) and I stil have the same problem. When I run it,it says ''Python has stop working".

OpenStudy (anonymous):

I already added '()' in line 336 but it still crashes.

OpenStudy (anonymous):

Can it crash if it returns too many news? It appears to crash when I use 'Syria' as a trigger.

OpenStudy (anonymous):

it is not crashing when i use it with Syria as a trigger - i am using v 2.7.2 I'm not getting any hits on Syria today here are my triggers http://dpaste.com/795200/

OpenStudy (anonymous):

try to play with it in the shell/idle use ctrl-c to stop the main loop and try to run the process function (see line 14 of this post) - http://dpaste.com/795203/ then you can see if that is working

OpenStudy (anonymous):

It is working now thanks.

OpenStudy (anonymous):

what was it??

OpenStudy (anonymous):

I am not sure. After I fixed the lack of brackets, I saved, closed and opened again and it was good to go.

OpenStudy (anonymous):

:)

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!