Commit 4126b009 authored by Matic Perovšek's avatar Matic Perovšek
parent b89e2c26
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
<input type="password" name="repeat_password"></input> <input type="password" name="repeat_password"></input>
<br/> <br/>
<div id="missing_error" class="invisible">All fields are mandatory</div> <div id="missing_error" class="invisible">All fields are mandatory</div>
<div id="unknown_error" class="invisible">An unknown error occured</div> <div id="unknown_error" class="invisible">An unknown error occurred</div>
<input type="submit" value="Sign up" style=""></input> <input type="submit" value="Sign up" style=""></input>
</form> </form>
......
...@@ -816,11 +816,12 @@ def run_widget(request): ...@@ -816,11 +816,12 @@ def run_widget(request):
w.running = False w.running = False
w.finished = False w.finished = False
w.save() w.save()
#raise #raise
for o in w.outputs.all(): for o in w.outputs.all():
o.value=None o.value=None
o.save() o.save()
data = simplejson.dumps({'status':'error','message':'Error occured when trying to execute widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>'}) data = simplejson.dumps({'status':'error','message':'Error occurred when trying to execute widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>'})
return HttpResponse(data,mimetype) return HttpResponse(data,mimetype)
else: else:
return HttpResponse(status=400) return HttpResponse(status=400)
...@@ -858,7 +859,7 @@ def run_tree(request): ...@@ -858,7 +859,7 @@ def run_tree(request):
for o in w.outputs.all(): for o in w.outputs.all():
o.value=None o.value=None
o.save() o.save()
data = simplejson.dumps({'status':'error','message':'Error occured when trying to execute widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>'}) data = simplejson.dumps({'status':'error','message':'Error occurred when trying to execute widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>'})
return HttpResponse(data,mimetype) return HttpResponse(data,mimetype)
else: else:
return HttpResponse(status=400) return HttpResponse(status=400)
...@@ -881,10 +882,15 @@ def reset_widget(request): ...@@ -881,10 +882,15 @@ def reset_widget(request):
w.running = False w.running = False
w.finished = False w.finished = False
w.save() w.save()
import traceback
print "asdfasdf"
print traceback.format_exc(e)
raise raise
for o in w.outputs.all(): for o in w.outputs.all():
o.value=None o.value=None
o.save() o.save()
data = simplejson.dumps({'status':'error','message':'Error occurred when trying to reset widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>'}) data = simplejson.dumps({'status':'error','message':'Error occurred when trying to reset widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>'})
return HttpResponse(data,mimetype) return HttpResponse(data,mimetype)
else: else:
...@@ -1116,7 +1122,7 @@ def finish_interaction(request): ...@@ -1116,7 +1122,7 @@ def finish_interaction(request):
for o in w.outputs.all(): for o in w.outputs.all():
o.value=None o.value=None
o.save() o.save()
data = simplejson.dumps({'status':'error','message':'Error occured when trying to execute widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>','widget_id':w.id}) data = simplejson.dumps({'status':'error','message':'Error occurred when trying to execute widget '+w.name+':<pre>'+str(sys.exc_info())+'</pre>','widget_id':w.id})
return HttpResponse(data,mimetype) return HttpResponse(data,mimetype)
else: else:
return HttpResponse(status=400) return HttpResponse(status=400)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment