diff --git a/server/fishtest/rundb.py b/server/fishtest/rundb.py index 3fc66945c..9a3ecf4a6 100644 --- a/server/fishtest/rundb.py +++ b/server/fishtest/rundb.py @@ -1033,7 +1033,7 @@ def sync_request_task(self, worker_info): if w["blocked"]: # updates last_updated self.workerdb.update_worker( - my_name, blocked=w["blocked"], message=w["message"], username=None + my_name, blocked=w["blocked"], message=None, username=None ) error = self.blocked_worker_message(my_name, w["message"], host_url) return {"task_waiting": False, "error": error} diff --git a/server/fishtest/schemas.py b/server/fishtest/schemas.py index 45ed5db4c..f6fc3746b 100644 --- a/server/fishtest/schemas.py +++ b/server/fishtest/schemas.py @@ -105,8 +105,16 @@ def size_is_length(x): "_id?": ObjectId, "worker_name": short_worker_name, "blocked": bool, - "message": worker_message, + "message?": worker_message, # old field, todo: remove this field from db records if exists + "notes?": intersect( + [ + {"time": datetime_utc, "username": username, "message": worker_message}, + ..., + ], + size(0, 100), # new field, todo: add this field to the db records if it doesn't exists + ), "last_updated": datetime_utc, + at_least_one_of("message", "notes"), } diff --git a/server/fishtest/templates/workers.mak b/server/fishtest/templates/workers.mak index e16e36922..66d966869 100644 --- a/server/fishtest/templates/workers.mak +++ b/server/fishtest/templates/workers.mak @@ -66,14 +66,20 @@