Commit 0eaf4df5 authored by Floreal Cabanettes's avatar Floreal Cabanettes
Browse files

Fix export fasta bug + remove debug lines

parent 8dfcf5fc
......@@ -100,7 +100,6 @@ d3.boxplot.events.stroke_linecap = function(rounded) {
};
d3.boxplot.events.stroke_width = function (width) {
console.log(width);
let stroke_width = d3.boxplot.scale / 600;
if (width === "1") {
stroke_width = d3.boxplot.scale / 400;
......@@ -111,7 +110,6 @@ d3.boxplot.events.stroke_width = function (width) {
else if (width === "3") {
stroke_width = d3.boxplot.scale / 100;
}
console.log(stroke_width);
d3.boxplot.content_lines_width = stroke_width;
d3.selectAll("path.content-lines").attr("stroke-width", stroke_width / d3.boxplot.zoom_scale_lines);
};
\ No newline at end of file
......@@ -63,7 +63,6 @@ dgenies.result.export.export_fasta = function(compress=false) {
gzip: compress
},
function(data, success) {
console.log(data);
if (data["status"] === 0) {
window.setTimeout(() => {
dgenies.result.export.export_fasta();
......
......@@ -181,9 +181,7 @@ class Functions:
@staticmethod
def sort_fasta(job_name, fasta_file, index_file, lock_file, compress=False, mailer=None):
print("Loading index...")
index, sample_name = Functions.read_index(index_file)
print("Starting fasta sort...")
is_compressed = fasta_file.endswith(".gz")
if is_compressed:
fasta_file = Functions.uncompress(fasta_file)
......@@ -198,17 +196,14 @@ class Functions:
if is_compressed:
os.remove(fasta_file)
if compress:
print("Compress...")
Functions.compress(fasta_file_o)
os.remove(lock_file)
if mailer is not None:
Functions.send_fasta_ready(mailer, job_name, sample_name, compress)
print("Fasta sort done!")
@staticmethod
def compress_and_send_mail(job_name, fasta_file, index_file, compressed, mailer):
print("Compress!")
def compress_and_send_mail(job_name, fasta_file, index_file, lock_file, compressed, mailer):
Functions.compress(fasta_file)
index, sample_name = Functions.read_index(index_file)
Functions.send_fasta_ready(mailer, job_name, sample_name, compressed)
print("DONE!")
\ No newline at end of file
os.remove(lock_file)
......@@ -235,6 +235,7 @@ def build_fasta(id_res):
"job_name": id_res,
"fasta_file": query_fasta,
"index_file": os.path.join(res_dir, "query.idx.sorted"),
"lock_file": lock_query,
"compressed": compressed,
"mailer": mailer
})
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment