fix python version check in server mode

Change-Id: I13e29126e7037007c74d5b14d93bad662e017fd3
use a 404 error when a run cannot be found in the db

Change-Id: I0bf3fb88ae635a8f056324ddf059b42782dac0fe