File tree Expand file tree Collapse file tree 3 files changed +17
-9
lines changed Expand file tree Collapse file tree 3 files changed +17
-9
lines changed Original file line number Diff line number Diff line change @@ -188,7 +188,7 @@ def update_redis_stats():
188
188
s = stat (fp )
189
189
stats .append ((dt , s .st_size , strftime ('%Y-%m' ,
190
190
localtime (s .st_ctime ))))
191
- except :
191
+ except OSError :
192
192
missing_files .append (fp )
193
193
194
194
summary = {}
Original file line number Diff line number Diff line change @@ -731,7 +731,7 @@ def purge_filepaths(delete_files=True):
731
731
Parameters
732
732
----------
733
733
delete_files : bool
734
- if True it will actually delete the files
734
+ if True it will actually delete the files, if False print
735
735
"""
736
736
with qdb .sql_connection .TRN :
737
737
# Get all the (table, column) pairs that reference to the filepath
@@ -785,7 +785,7 @@ def empty_trash_upload_folder(delete_files=True):
785
785
Parameters
786
786
----------
787
787
delete_files : bool
788
- if True it will actually delete the files
788
+ if True it will actually delete the files, if False print
789
789
"""
790
790
gfp = partial (join , get_db_files_base_dir ())
791
791
with qdb .sql_connection .TRN :
Original file line number Diff line number Diff line change 63
63
< tr >
64
64
< td >
65
65
{% for k in number_studies %}
66
- < i > {{k}}</ i > : {{number_studies[k]}} < br />
66
+ < i > {{k}}</ i > : {{ "{:,}".format(int(number_studies[k])) }} < br />
67
+ {% end %}
68
+ {% if num_studies_ebi and num_studies_ebi is not None %}
69
+ < i > submitted to EBI</ i > : {{ "{:,}".format(int(num_studies_ebi)) }}
67
70
{% end %}
68
- < i > submitted to EBI</ i > : {{ num_studies_ebi }}
69
71
</ td >
70
72
< td >
71
73
{% for k in number_of_samples %}
72
- < i > {{k}}</ i > : {{number_of_samples[k]}} < br />
74
+ < i > {{k}}</ i > : {{ "{:,}".format(int(number_of_samples[k])) }} < br />
75
+ {% end %}
76
+ {% if num_samples_ebi and num_samples_ebi is not None %}
77
+ < i > submitted to EBI</ i > : {{ "{:,}".format(int(num_samples_ebi)) }} < br />
78
+ {% end %}
79
+ {% if number_samples_ebi_prep and number_samples_ebi_prep is not None %}
80
+ < i > submitted to EBI (prep)</ i > : {{ "{:,}".format(int(number_samples_ebi_prep)) }}
73
81
{% end %}
74
- < i > submitted to EBI</ i > : {{ num_samples_ebi }} < br />
75
- < i > submitted to EBI (prep)</ i > : {{ number_samples_ebi_prep }}
76
82
</ td >
77
- < td > {{ num_users }}</ td >
83
+ {% if num_users and num_users is not None %}
84
+ < td > {{ "{:,}".format(int(num_users)) }}</ td >
85
+ {% end %}
78
86
</ tr >
79
87
</ table >
80
88
</ div >
You can’t perform that action at this time.
0 commit comments