From 9686f3023583c60b4e1f9c42c1b80060d8d7e32c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9CAyesha?= Date: Mon, 4 Mar 2024 10:59:04 +0100 Subject: [PATCH] IRfinder form debugged --- routes/apps/irfinder.py | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/routes/apps/irfinder.py b/routes/apps/irfinder.py index 5664401f..e4bdd149 100644 --- a/routes/apps/irfinder.py +++ b/routes/apps/irfinder.py @@ -306,12 +306,13 @@ def _generate_submission_file(rows, email,group,folder,md5sums,project_title,org nf={ "r2d2":{ - "project_folder" : os.path.join(paths["r2d2"]["run_data"], project_folder) , + "project_folder" : os.path.join(paths["r2d2"]["run_data"], project_folder, "/") , "samplestable":os.path.join(paths["r2d2"]["code"], project_folder, "scripts.JBoucas" ,"sample_sheet.xlsx"), - "fastqc_raw_data" : os.path.join(paths["r2d2"]["run_data"], project_folder, "raw_data") , - "IRquant_raw_data" : os.path.join(paths["r2d2"]["run_data"], project_folder, "raw_data"), + "fastqc_raw_data" : os.path.join(paths["r2d2"]["run_data"], project_folder, "raw_data/") , + "IRquant_raw_data" : os.path.join(paths["r2d2"]["run_data"], project_folder, "raw_data/"), + "scripts" : os.path.join(paths["r2d2"]["code"], project_folder, "scripts.JBoucas/"), "kallisto_raw_data" : "" , - "genomes" : "/beegfs/common/genomes/nextflow_builds" , + "genomes" : "/beegfs/common/genomes/nextflow_builds/" , "read1_sufix" : ".READ_1.fastq.gz", "fastqc_output" : "fastqc_output", "mapping_output" : "", @@ -319,10 +320,11 @@ def _generate_submission_file(rows, email,group,folder,md5sums,project_title,org }, "raven":{ - "project_folder" : os.path.join(paths["raven"]["run_data"], project_folder) , + "project_folder" : os.path.join(paths["raven"]["run_data"], project_folder, "/") , "samplestable":os.path.join(paths["raven"]["code"], project_folder, "scripts.flaski" ,"sample_sheet.xlsx"), - "fastqc_raw_data" : os.path.join(paths["raven"]["run_data"], project_folder, "raw_data") , - "IRquant_raw_data" : os.path.join(paths["raven"]["run_data"], project_folder, "raw_data"), + "fastqc_raw_data" : os.path.join(paths["raven"]["run_data"], project_folder, "raw_data/") , + "IRquant_raw_data" : os.path.join(paths["raven"]["run_data"], project_folder, "raw_data/"), + "scripts" : os.path.join(paths["raven"]["code"], project_folder, "scripts.flaski/"), "kallisto_raw_data" : "" , "genomes" : "/nexus/posix0/MAGE-flaski/service/genomes/IRfinder/" , "read1_sufix" : ".READ_1.fastq.gz", @@ -331,10 +333,11 @@ def _generate_submission_file(rows, email,group,folder,md5sums,project_title,org "featurecounts" : "" }, "studio":{ - "project_folder" : os.path.join(paths["studio"]["run_data"], project_folder) , + "project_folder" : os.path.join(paths["studio"]["run_data"], project_folder, "/") , "samplestable":os.path.join(paths["studio"]["code"], project_folder, "scripts.flaski" ,"sample_sheet.xlsx"), - "fastqc_raw_data" : os.path.join(paths["studio"]["run_data"], project_folder, "raw_data") , - "IRquant_raw_data" : os.path.join(paths["studio"]["run_data"], project_folder, "raw_data"), + "fastqc_raw_data" : os.path.join(paths["studio"]["run_data"], project_folder, "raw_data/") , + "IRquant_raw_data" : os.path.join(paths["studio"]["run_data"], project_folder, "raw_data/"), + "scripts" : os.path.join(paths["studio"]["code"], project_folder, "scripts.flaski/"), "kallisto_raw_data" : "" , "genomes" : "/nexus/posix0/MAGE-flaski/service/genomes/IRfinder/" , "read1_sufix" : ".READ_1.fastq.gz", @@ -780,8 +783,6 @@ def update_output(n_clicks, rows, email, group, folder, md5sums, project_title, samples=pd.read_json(json_config[filename]["samples"]) metadata=pd.read_json(json_config[filename]["IRfinder"]) - print(metadata) - validation=validate_metadata(metadata) if validation: header="Attention" @@ -815,8 +816,6 @@ def update_output(n_clicks, rows, email, group, folder, md5sums, project_title, ftp_user=send_submission_ftp_email(user=current_user, submission_type="IRfinder", submission_tag=json_filename, submission_file=json_filename, attachment_path=json_filename, ftp_user=ftp) metadata=pd.concat([metadata,ftp_user]) - print(metadata) - EXCout=pd.ExcelWriter(filename) samples.to_excel(EXCout,"samples",index=None) metadata.to_excel(EXCout,"IRfinder",index=None)