Updated Local Bottle Script with try...except to return valid JSON always