Python problem

i'm new to python when I run this script
import wap
import speech

speech.say("Awaiting Command")
question = speech.input("Awaiting Command")
appid = '3HA463-A3RT78PEA8' # Use your app id
waeo = wap.WolframAlphaEngine(appid)
waeq = wap.WolframAlphaQuery(question, appid)
waeq.ScanTimeout = '3.0'
waeq.Async = False
waeq.ToURL() # After configuring the waeq must call ToURL()
result = waeo.PerformQuery(waeq.Query) # result is in xml format
print result 
waeq = wap.WolframAlphaQueryResult(result)
for pod in waeq.Pods():
  waep = wap.Pod(pod)
  print '\n%s: (%d subpods)' % (waep.Title(), waep.NumSubpods())
speech.say('\n%s: (%d subpods)' % (waep.Title(), waep.NumSubpods()))

it gives me this error Can anyone diagnose this problem. Thanks in advanced
1 answer Last reply
More about python problem
  1. I'm no expert in python, but it looks like it's trying to convert a string into a number, that's why it's failing.
Ask a new question

Read More

Programming Python Wireless Access Command Prompt Apps