This commit is contained in:
Casper 2019-04-06 19:11:40 +02:00
parent ef1884445a
commit e2c7880ca2
No known key found for this signature in database
GPG Key ID: 289CA03790535054

View File

@ -34,9 +34,11 @@ strategies = {
@app.route("/", methods=["GET", "POST"])
def probabilities():
if request.method == 'GET':
logger.warning("GET request: using default context parameters")
phone_data = request.get_json(force=True)
context = Context(**phone_data)
logger.debug("phone_data:\n%s", json.dumps(phone_data, indent=2))
context = Context(**phone_data)
logger.debug("Context: %s", context)
predictions: List[dict] = []