From 96c600723726c3391532d86d17183bea960ece57 Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Wed, 24 Jan 2024 10:40:59 +0300 Subject: redis-prefix: update "upload samples" path --- qc_app/samples.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'qc_app') diff --git a/qc_app/samples.py b/qc_app/samples.py index bf33715..cf97b8d 100644 --- a/qc_app/samples.py +++ b/qc_app/samples.py @@ -240,6 +240,7 @@ def upload_samples(): the_job = jobs.launch_job( jobs.initialise_job( rconn, + jobs.jobsnamespace(), str(uuid.uuid4()), build_sample_upload_job( species["SpeciesId"], @@ -259,7 +260,8 @@ def upload_samples(): @samples.route("/upload/status/", methods=["GET"]) def upload_status(job_id: uuid.UUID): """Check on the status of a samples upload job.""" - job = with_redis_connection(lambda rconn: jobs.job(rconn, str(job_id))) + job = with_redis_connection(lambda rconn: jobs.job( + rconn, jobs.jobsnamespace(), job_id)) if job: status = job["status"] if status == "success": @@ -285,7 +287,8 @@ def upload_status(job_id: uuid.UUID): @samples.route("/upload/failure/", methods=["GET"]) def upload_failure(job_id: uuid.UUID): """Display the errors of the samples upload failure.""" - job = with_redis_connection(lambda rconn: jobs.job(rconn, str(job_id))) + job = with_redis_connection(lambda rconn: jobs.job( + rconn, jobs.jobsnamespace(), job_id)) if not bool(job): return render_template("no_such_job.html", job_id=job_id), 400 -- cgit v1.2.3