Commit 38af32ff authored by Vidjil Team's avatar Vidjil Team

merge rebased commits from 'rbx'

parents d2a456fe 385fc437
......@@ -302,8 +302,8 @@ def run_fuse(id_file, id_config, id_data, id_fuse, sample_set_id, clean_before=T
files += defs.DIR_RESULTS + row.results_file.data_file + " "
sequence_file_list += str(row.results_file.sequence_file_id) + "_"
cmd = "python "+defs.DIR_FUSE+"/fuse.py -o "+output_file+" -t 100 "+files
fuse_cmd = db.config[id_config].fuse_command
cmd = "python "+defs.DIR_FUSE+"/fuse.py -o "+ output_file + " " + fuse_cmd + " " + files
print "=== fuse.py ==="
......
import defs
import os.path
def rbx_link(patient_id, config_id):
return 'http://rbx.vidjil.org/browser/?patient=%d&config=%d' % (patient_id,config_id)
def print_patient_info(patient_id):
patient = db.patient[patient_id]
print "%3s" % patient_id,
print "%-25s" % (patient.first_name + ' ' + patient.last_name),
def print_config_info(config_id):
config = db.config[config_id]
print "%s" % config.name,
def print_sequence_file(res):
fused_files = db(db.fused_file.sequence_file_list.contains('%d_' % res.id)).select()
print "%5s" % res.id, "%2s" % res.provider, "%-20s" % res.producer,
print_patient_info(res.patient_id)
print "%s\t%s" % (res.filename, res.data_file),
for fused in fused_files:
if fused is not None and fused != '<NULL>':
print rbx_link(res.patient_id, fused.config_id),
print
def print_results_file(res):
seq = db.sequence_file[res.sequence_file_id]
print "%5s\t%s\t" % (res.id, res.data_file),
print_config_info(res.config_id)
print "\t%s\t%s" % (seq.filename, seq.data_file),
print rbx_link(seq.patient_id, res.config_id)
def print_fused_file(res):
print "%5s\t%s\t%s\t" % (res.id, res.sequence_file_list, res.fused_file),
print_patient_info(res.patient_id)
print_config_info(res.config_id)
print rbx_link(res.patient_id, res.config_id)
def print_analysis_file(res):
print "%5s" % (res.id)
print_patient_info(res.patient_id)
print_config_info(res.config_id)
print rbx_link(res.patient_id, res.config_id)
print "** Missing sequences **"
for res in db(db.sequence_file).select():
if not os.path.isfile(defs.DIR_SEQUENCES+res.data_file):
print_sequence_file(res)
print "** Missing results **"
for res in db(db.results_file).select():
if res.data_file is not None and not os.path.isfile(defs.DIR_RESULTS+res.data_file):
print_results_file(res)
print "** Missing fused **"
for res in db(db.fused_file).select():
if res.fused_file is not None and not os.path.isfile(defs.DIR_RESULTS+res.fused_file):
print_fused_file(res)
print "** Missing analysis **"
for res in db(db.analysis_file).select():
if res.analysis_file is not None and not os.path.isfile(defs.DIR_RESULTS+res.analysis_file):
print_analysis_file(res)
#!/bin/sh
(echo "Subject: [rbx] Vidjil Morning" ; sh stats.sh ) | sendmail notifications@vidjil.org
#!/bin/sh
sudo -u www-data python ../../../web2py.py -S vidjil -M -R applications/vidjil/scripts//db-stats.py 2> /dev/null
echo -n "=== Server health"
/etc/update-motd.d/50-landscape-sysinfo
/etc/update-motd.d/60-df
/etc/update-motd.d/90-updates-available
/etc/update-motd.d/98-reboot-required
......@@ -25,6 +25,9 @@
<a class="button" onclick="db.call('admin/showlog', {'file' : '../log/nginx/access.log'} );">access.log</a>
<a class="button" onclick="db.call('admin/showlog', {'file' : '../log/nginx/error.log'} );">error.log</a>
</br>System:
<a class="button" onclick="db.call('admin/showlog', {'file' : '../log/syslog'} );">syslog</a>
</br>
......
......@@ -12,6 +12,7 @@
<td class="column2"> name </td>
<td class="column1"> program </td>
<td> command </td>
<td class="column_100"> fuse </td>
<td> info </td>
<td class="column5"> </td>
......@@ -27,6 +28,7 @@
<td> {{=row.name }} </td>
<td> {{=row.program }} </td>
<td> {{=row.command }} </td>
<td> {{=row.fuse_command }} </td>
<td> {{=row.info }} </td>
{{if isAdmin:}} <td onclick="db.call('config/permission', {'id' :'{{=row.id}}'} )" > p </td> {{else:}} <td></td> {{pass}}
......
......@@ -21,11 +21,13 @@
{{if not 'register' in auth.settings.actions_disabled:}}
{{#<button class="btn" onclick="db.call('default/user/register')">Register</button>}}
{{pass}}
<!--
{{if not 'request_reset_password' in auth.settings.actions_disabled:}}
<button class="btn" onclick="db.call('default/user/request_reset_password')">Lost Password</button>
{{pass}}
-->
<p>
demo login: <i>demo@vidjil.org</i>
<br />password: <i>demo</i>
......
......@@ -330,6 +330,9 @@ class ListWindows(VidjilJson):
with open(file_path, "r") as file:
tmp = json.load(file, object_hook=self.toPython)
self.d=tmp.d
# Be robust against 'null' values for clones
if not self.d["clones"]:
self.d["clones"] = []
self.check_version(file_path)
if 'distribution' not in self.d['reads'].d:
......
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