@app.route('/sync/<uid>', methods=['GET'])
def load(uid=None):
    app.logger.info("GET /sync route with id: %s" % uid)

    try:
        user = Participant.query.\
            filter(Participant.uniqueid == uid).\
            one()
    except exc.SQLAlchemyError:
        app.logger.error("DB error: Unique user not found.")

    try:
        resp = json.loads(user.datastring)
    except:
        resp = {
            "condition": user.cond,
            "counterbalance": user.counterbalance,
            "assignmentId": user.assignmentid,
            "workerId": user.workerid,
            "hitId": user.hitid,
            "bonus": user.bonus
        }

    return jsonify(**resp)
Stops the web server and wait until it has sucesfully cleaned up.
dataset/ETHPy150Open NYUCCL/psiTurk/psiturk/experiment.py/load--crossover with--dataset/ETHPy150Open owtf/owtf/tests/testing_framework/server.py/WebServerProcess.stop