genevalidatorapp 1.5.3 → 1.5.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +8 -2
- data/bin/genevalidatorapp +27 -18
- data/docker/Dockerfile +21 -0
- data/lib/genevalidatorapp.rb +21 -27
- data/lib/genevalidatorapp/config.rb +2 -2
- data/lib/genevalidatorapp/exceptions.rb +25 -13
- data/lib/genevalidatorapp/genevalidator.rb +23 -36
- data/lib/genevalidatorapp/version.rb +1 -1
- data/public/GeneValidator/loading.html +1 -1
- data/views/layout.slim +8 -11
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 955fcd74d359c54ce421064d7aced2408857e7dc
|
4
|
+
data.tar.gz: 1c35fb396c2c5a0a059d265944c6e9299e8af259
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0d188f08c4144fa3351c78d2c1e3cde7602dab41fed60c50a60cb371dce1a340852498f738b223aaeca6d9b8d47a99ba1af61f2c1d1b3a9097658df42e8e686c
|
7
|
+
data.tar.gz: c1be3117819f1efdcb9c92150da757e6a9f0daff2062c9e0f25782ae5d21db95335360338cf82f52c76eb539c4f557c87408023224bd74d454c86add87d4c3ab
|
data/README.md
CHANGED
@@ -16,7 +16,7 @@ This is a online web application for [GeneValidator](https://github.com/wurmlab/
|
|
16
16
|
GeneValidator helps in identifing problems with gene predictions and provides useful information extracted from analysing orthologs in BLAST databases. The results produced can be used by biocurators and researchers who need accurate gene predictions.
|
17
17
|
|
18
18
|
If you use GeneValidator in your work, please cite us as follows:
|
19
|
-
>
|
19
|
+
> [Dragan M<sup>‡</sup>, Moghul MI<sup>‡</sup>, Priyam A, Bustos C & Wurm Y. 2016. GeneValidator: identify problems with protein-coding gene predictions. <em>Bioinformatics</em>, doi: 10.1093/bioinformatics/btw015](http://bioinformatics.oxfordjournals.org/content/early/2016/01/18/bioinformatics.btw015).
|
20
20
|
|
21
21
|
|
22
22
|
|
@@ -28,7 +28,7 @@ If you use GeneValidator in your work, please cite us as follows:
|
|
28
28
|
### Installation Requirements
|
29
29
|
* Ruby (>= 2.0.0)
|
30
30
|
* NCBI BLAST+ (>= 2.2.30+) (download [here](http://blast.ncbi.nlm.nih.gov/Blast.cgi?PAGE_TYPE=BlastDocs&DOC_TYPE=Download)).
|
31
|
-
* MAFFT installation (download [here](http://mafft.cbrc.jp/alignment/software/)).
|
31
|
+
* MAFFT installation (>=7.273) (download [here](http://mafft.cbrc.jp/alignment/software/)).
|
32
32
|
|
33
33
|
Please see [here](https://gist.github.com/IsmailM/b783e8a06565197084e6) for more help with installing the prerequisites.
|
34
34
|
|
@@ -126,6 +126,12 @@ Examples:
|
|
126
126
|
```
|
127
127
|
|
128
128
|
|
129
|
+
## Using Docker
|
130
|
+
```bash
|
131
|
+
# With protein database files inside a folder named db
|
132
|
+
docker run --rm -ti -p 4567:4567 -v $(pwd)/db:/db wurmlab/genevalidator
|
133
|
+
```
|
134
|
+
|
129
135
|
<hr>
|
130
136
|
|
131
137
|
This program was developed at [Wurm Lab](https://wurmlab.github.io), [QMUL](http://sbcs.qmul.ac.uk) with the support of a BBSRC grant.
|
data/bin/genevalidatorapp
CHANGED
@@ -34,6 +34,10 @@ BANNER
|
|
34
34
|
'Use the given configuration file',
|
35
35
|
argument: true
|
36
36
|
|
37
|
+
on 'g', 'gv_public_dir=',
|
38
|
+
'The public directory that is served to the web application.',
|
39
|
+
argument: true
|
40
|
+
|
37
41
|
on 'b', 'bin=',
|
38
42
|
'Load BLAST+ and/or MAFFT binaries from this directory',
|
39
43
|
argument: true,
|
@@ -111,59 +115,58 @@ BANNER
|
|
111
115
|
# error scenarios either when creating a new GeneValidatorApp (first
|
112
116
|
# time or later), or updating config values using -s CLI option.
|
113
117
|
|
114
|
-
rescue GeneValidatorApp::CONFIG_FILE_ERROR
|
115
|
-
GeneValidatorApp::BLAST_DATABASE_ERROR => e
|
118
|
+
rescue GeneValidatorApp::CONFIG_FILE_ERROR => e
|
116
119
|
|
117
120
|
puts e
|
118
121
|
exit!
|
119
122
|
|
120
|
-
rescue GeneValidatorApp::
|
123
|
+
rescue GeneValidatorApp::NUM_THREADS_INCORRECT => e
|
121
124
|
|
122
125
|
puts e
|
123
126
|
|
124
|
-
unless
|
127
|
+
unless num_threads?
|
125
128
|
puts 'You can set the correct value by running:'
|
126
129
|
puts
|
127
|
-
puts ' genevalidatorapp -s -
|
130
|
+
puts ' genevalidatorapp -s -n <value>'
|
128
131
|
puts
|
129
132
|
end
|
130
133
|
|
131
134
|
exit!
|
132
135
|
|
133
|
-
rescue GeneValidatorApp::
|
136
|
+
rescue GeneValidatorApp::BIN_DIR_NOT_FOUND => e
|
134
137
|
|
135
138
|
puts e
|
136
139
|
|
137
|
-
unless
|
140
|
+
unless bin?
|
138
141
|
puts 'You can set the correct value by running:'
|
139
142
|
puts
|
140
|
-
puts ' genevalidatorapp -s -
|
143
|
+
puts ' genevalidatorapp -s -b <value>'
|
141
144
|
puts
|
142
145
|
end
|
143
146
|
|
144
147
|
exit!
|
145
148
|
|
146
|
-
rescue GeneValidatorApp::
|
149
|
+
rescue GeneValidatorApp::EXTENSION_FILE_NOT_FOUND => e
|
147
150
|
|
148
151
|
puts e
|
149
152
|
|
150
|
-
unless
|
153
|
+
unless require?
|
151
154
|
puts 'You can set the correct value by running:'
|
152
155
|
puts
|
153
|
-
puts ' genevalidatorapp -s -
|
156
|
+
puts ' genevalidatorapp -s -r <value>'
|
154
157
|
puts
|
155
158
|
end
|
156
159
|
|
157
160
|
exit!
|
158
161
|
|
159
|
-
rescue GeneValidatorApp::
|
162
|
+
rescue GeneValidatorApp::DATABASE_DIR_NOT_FOUND => e
|
160
163
|
|
161
164
|
puts e
|
162
165
|
|
163
|
-
unless
|
166
|
+
unless database_dir?
|
164
167
|
puts 'You can set the correct value by running:'
|
165
168
|
puts
|
166
|
-
puts ' genevalidatorapp -s -
|
169
|
+
puts ' genevalidatorapp -s -d <value>'
|
167
170
|
puts
|
168
171
|
end
|
169
172
|
|
@@ -200,6 +203,7 @@ MSG
|
|
200
203
|
redo
|
201
204
|
end
|
202
205
|
|
206
|
+
|
203
207
|
rescue GeneValidatorApp::DATABASE_DIR_NOT_SET => e
|
204
208
|
|
205
209
|
# Show original error message.
|
@@ -225,15 +229,20 @@ MSG
|
|
225
229
|
fetch_option(:database_dir).value = response
|
226
230
|
redo
|
227
231
|
|
228
|
-
rescue GeneValidatorApp::NO_BLAST_DATABASE_FOUND
|
232
|
+
rescue GeneValidatorApp::NO_BLAST_DATABASE_FOUND,
|
233
|
+
GeneValidatorApp::NO_PROTEIN_BLAST_DATABASE_FOUND => e
|
229
234
|
unless list_databases?
|
230
|
-
|
231
235
|
# Print error raised.
|
232
236
|
puts
|
233
237
|
puts e
|
234
|
-
|
238
|
+
exit!
|
235
239
|
end
|
236
240
|
|
241
|
+
rescue GeneValidatorApp::BLAST_DATABASE_ERROR => e
|
242
|
+
|
243
|
+
puts e
|
244
|
+
exit!
|
245
|
+
|
237
246
|
rescue => e
|
238
247
|
# This will catch any unhandled error and some very special errors.
|
239
248
|
# Ideally we will never hit this block. If we do, there's a bug in
|
@@ -250,7 +259,7 @@ https://github.com/wurmlab/genevalidatorapp/issues
|
|
250
259
|
Error:
|
251
260
|
#{e.backtrace.unshift(e.message).join("\n")}
|
252
261
|
MSG
|
253
|
-
exit
|
262
|
+
exit!
|
254
263
|
end
|
255
264
|
|
256
265
|
if list_databases?
|
data/docker/Dockerfile
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
# GeneValidator
|
2
|
+
#
|
3
|
+
# A web wrapper for GeneValidator (identify problems with predicted genes)
|
4
|
+
#
|
5
|
+
# If you use GeneValidator in your work, please cite us as follows:
|
6
|
+
#
|
7
|
+
# Dragan M‡, Moghul MI‡, Priyam A, Bustos C & Wurm Y. 2016.
|
8
|
+
# GeneValidator: identify problems with protein-coding gene predictions.
|
9
|
+
# Bioinformatics, doi: 10.1093/bioinformatics/btw015.
|
10
|
+
#
|
11
|
+
# VERSION 1.0.0
|
12
|
+
|
13
|
+
FROM ubuntu:16.04
|
14
|
+
MAINTAINER Bruno Vieira <mail@bmpvieira.com>
|
15
|
+
|
16
|
+
LABEL Description="Identify problems with protein-coding gene predictions http://genevalidator.sbcs.qmul.ac.uk" Version="1.0.0"
|
17
|
+
|
18
|
+
RUN apt-get update
|
19
|
+
RUN apt-get install -y build-essential ruby ruby-dev ncbi-blast+ mafft zlib1g-dev libgsl0-dev
|
20
|
+
RUN gem install genevalidatorapp
|
21
|
+
CMD genevalidatorapp -d /db
|
data/lib/genevalidatorapp.rb
CHANGED
@@ -38,9 +38,7 @@ module GeneValidatorApp
|
|
38
38
|
init_binaries
|
39
39
|
init_database
|
40
40
|
|
41
|
-
|
42
|
-
init_gv_tempdir
|
43
|
-
init_public_dir
|
41
|
+
init_dirs
|
44
42
|
|
45
43
|
load_extension
|
46
44
|
check_num_threads
|
@@ -77,8 +75,9 @@ module GeneValidatorApp
|
|
77
75
|
puts
|
78
76
|
puts '** Thank you for using GeneValidatorApp :).'
|
79
77
|
puts ' Please cite: '
|
80
|
-
puts ' Dragan M
|
81
|
-
puts ' GeneValidator: identify
|
78
|
+
puts ' Dragan M, Moghul MI, Priyam A, Bustos C, Wurm Y. 2016.'
|
79
|
+
puts ' GeneValidator: identify problems with protein-coding gene'
|
80
|
+
puts ' predictions. Bioinformatics, doi: 10.1093/bioinformatics/btw015.'
|
82
81
|
end
|
83
82
|
|
84
83
|
# Rack-interface.
|
@@ -91,23 +90,17 @@ module GeneValidatorApp
|
|
91
90
|
|
92
91
|
private
|
93
92
|
|
94
|
-
def
|
95
|
-
config[:
|
96
|
-
|
97
|
-
@public_dir
|
98
|
-
|
99
|
-
end
|
100
|
-
|
101
|
-
# Creates a Temp directory (starting with 'GeneValidator_') each time
|
102
|
-
# GVapp is started. Within this Temp folder, sub directories are created
|
103
|
-
# in which GeneValidator is run.
|
104
|
-
def init_gv_tempdir
|
105
|
-
@temp_dir = Dir.mktmpdir('GeneValidator_')
|
93
|
+
def init_dirs
|
94
|
+
config[:gv_public_dir] = File.expand_path(config[:gv_public_dir])
|
95
|
+
unique_start_id = 'GV_' + "#{Time.now.strftime('%Y%m%d-%H-%M-%S')}"
|
96
|
+
@public_dir = File.join(config[:gv_public_dir], unique_start_id)
|
97
|
+
init_public_dir
|
106
98
|
end
|
107
99
|
|
108
|
-
#
|
109
|
-
#
|
100
|
+
# Create the Public Dir and copy files from gem root - this public dir
|
101
|
+
# is served by the app is accessible at URL/...
|
110
102
|
def init_public_dir
|
103
|
+
FileUtils.mkdir_p(File.join(@public_dir, 'GeneValidator'))
|
111
104
|
root_web_files = File.join(GeneValidatorApp.root, 'public/web_files')
|
112
105
|
root_gv = File.join(GeneValidatorApp.root, 'public/GeneValidator')
|
113
106
|
FileUtils.cp_r(root_web_files, @public_dir)
|
@@ -151,12 +144,16 @@ module GeneValidatorApp
|
|
151
144
|
end
|
152
145
|
|
153
146
|
def assert_blast_databases_present_in_database_dir
|
154
|
-
cmd = "blastdbcmd -recursive -list #{config[:database_dir]}"
|
147
|
+
cmd = "blastdbcmd -recursive -list '#{config[:database_dir]}'"
|
155
148
|
out = `#{cmd}`
|
156
149
|
errpat = /BLAST Database error/
|
157
150
|
fail NO_BLAST_DATABASE_FOUND, config[:database_dir] if out.empty?
|
158
151
|
fail BLAST_DATABASE_ERROR, cmd, out if out.match(errpat) ||
|
159
152
|
!$CHILD_STATUS.success?
|
153
|
+
type = []
|
154
|
+
out.lines.each { |l| type << l.split[1] }
|
155
|
+
return if type.include? 'Protein'
|
156
|
+
fail NO_PROTEIN_BLAST_DATABASE_FOUND, config[:database_dir]
|
160
157
|
end
|
161
158
|
|
162
159
|
def check_num_threads
|
@@ -181,7 +178,7 @@ module GeneValidatorApp
|
|
181
178
|
|
182
179
|
def init_bins
|
183
180
|
bins = []
|
184
|
-
config[:bin].each do |bin|
|
181
|
+
Array(config[:bin]).each do |bin|
|
185
182
|
bins << File.expand_path(bin)
|
186
183
|
unless File.exist?(bin) && File.directory?(bin)
|
187
184
|
fail BIN_DIR_NOT_FOUND, config[:bin]
|
@@ -210,12 +207,9 @@ module GeneValidatorApp
|
|
210
207
|
|
211
208
|
# Check and warn user if host is 0.0.0.0 (default).
|
212
209
|
def check_host
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
' Consider using 127.0.0.1 (--host option).'
|
217
|
-
end
|
218
|
-
# rubocop:enable Style/GuardClause
|
210
|
+
return unless config[:host] == '0.0.0.0'
|
211
|
+
logger.warn 'Will listen on all interfaces (0.0.0.0).' \
|
212
|
+
' Consider using 127.0.0.1 (--host option).'
|
219
213
|
end
|
220
214
|
|
221
215
|
def server_url
|
@@ -75,8 +75,8 @@ module GeneValidatorApp
|
|
75
75
|
:num_threads => 1,
|
76
76
|
:port => 4567,
|
77
77
|
:host => '0.0.0.0',
|
78
|
-
:
|
79
|
-
:max_characters => 'undefined'
|
78
|
+
:gv_public_dir => File.join(Dir.home, '.genevalidatorapp/'),
|
79
|
+
:max_characters => 'undefined',
|
80
80
|
}
|
81
81
|
end
|
82
82
|
|
@@ -29,6 +29,14 @@ MSG
|
|
29
29
|
end
|
30
30
|
end
|
31
31
|
|
32
|
+
## NUM THREADS ##
|
33
|
+
# Raised if num_threads set by the user is incorrect.
|
34
|
+
class NUM_THREADS_INCORRECT < StandardError
|
35
|
+
def to_s
|
36
|
+
'Number of threads should be a number greater than or equal to 1.'
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
32
40
|
## ENOENT ##
|
33
41
|
|
34
42
|
# Name borrowed from standard Errno::ENOENT, this class serves as a template
|
@@ -59,13 +67,6 @@ MSG
|
|
59
67
|
end
|
60
68
|
end
|
61
69
|
|
62
|
-
# Raised if database dir set, but does not exist.
|
63
|
-
class DATABASE_DIR_NOT_FOUND < ENOENT
|
64
|
-
def initialize(ent)
|
65
|
-
super 'database dir', ent
|
66
|
-
end
|
67
|
-
end
|
68
|
-
|
69
70
|
# Raised if extension file set, but does not exist.
|
70
71
|
class EXTENSION_FILE_NOT_FOUND < ENOENT
|
71
72
|
def initialize(ent)
|
@@ -73,12 +74,10 @@ MSG
|
|
73
74
|
end
|
74
75
|
end
|
75
76
|
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
def to_s
|
81
|
-
'Number of threads should be a number greater than or equal to 1.'
|
77
|
+
# Raised if database dir set, but does not exist.
|
78
|
+
class DATABASE_DIR_NOT_FOUND < ENOENT
|
79
|
+
def initialize(ent)
|
80
|
+
super 'database dir', ent
|
82
81
|
end
|
83
82
|
end
|
84
83
|
|
@@ -139,6 +138,19 @@ MSG
|
|
139
138
|
end
|
140
139
|
end
|
141
140
|
|
141
|
+
# Raised if no protein BLAST+ database was found in database_dir.
|
142
|
+
class NO_PROTEIN_BLAST_DATABASE_FOUND < StandardError
|
143
|
+
def initialize(database_dir)
|
144
|
+
@database_dir = database_dir
|
145
|
+
end
|
146
|
+
|
147
|
+
attr_reader :database_dir
|
148
|
+
|
149
|
+
def to_s
|
150
|
+
"Could not find any Protein BLAST+ databases in: #{database_dir}."
|
151
|
+
end
|
152
|
+
end
|
153
|
+
|
142
154
|
# Raised if there was an error determining BLAST+ databases in database_dir.
|
143
155
|
class BLAST_DATABASE_ERROR < StandardError
|
144
156
|
def initialize(cmd, out)
|
@@ -27,14 +27,12 @@ module GeneValidatorApp
|
|
27
27
|
|
28
28
|
def_delegators GeneValidatorApp, :config, :logger, :public_dir
|
29
29
|
|
30
|
-
attr_reader :gv_dir, :
|
31
|
-
:unique_id, :params
|
30
|
+
attr_reader :gv_dir, :input_file, :xml_file, :raw_seq, :unique_id, :params
|
32
31
|
|
33
32
|
# Setting the scene
|
34
33
|
def init(url, params)
|
35
34
|
create_unique_id
|
36
|
-
|
37
|
-
create_soft_link_from_tmpdir_to_gv_dir
|
35
|
+
create_run_dir
|
38
36
|
@params = params
|
39
37
|
validate_params
|
40
38
|
obtain_db_path
|
@@ -42,8 +40,7 @@ module GeneValidatorApp
|
|
42
40
|
@url = produce_result_url_link(url)
|
43
41
|
end
|
44
42
|
|
45
|
-
#
|
46
|
-
# Returns html for just the table or a link to the page produced by GV
|
43
|
+
# Runs genevalidator & Returns parsed JSON, or link to JSON/results file
|
47
44
|
def run
|
48
45
|
write_seq_to_file
|
49
46
|
run_genevalidator
|
@@ -57,32 +54,26 @@ module GeneValidatorApp
|
|
57
54
|
# Creates a unique run ID (based on time),
|
58
55
|
def create_unique_id
|
59
56
|
@unique_id = Time.new.strftime('%Y-%m-%d_%H-%M-%S_%L-%N')
|
60
|
-
@
|
57
|
+
@run_dir = File.join(GeneValidatorApp.public_dir, 'GeneValidator',
|
58
|
+
@unique_id)
|
61
59
|
ensure_unique_id
|
62
60
|
end
|
63
61
|
|
64
62
|
# Ensures that the Unique id is unique (if a sub dir is present in the
|
65
63
|
# temp dir with the unique id, it simply creates a new one)
|
66
64
|
def ensure_unique_id
|
67
|
-
while File.exist?(@
|
65
|
+
while File.exist?(@run_dir)
|
68
66
|
@unique_id = create_unique_id
|
69
|
-
@
|
67
|
+
@run_dir = File.join(GeneValidatorApp.public_dir, 'GeneValidator',
|
68
|
+
@unique_id)
|
70
69
|
end
|
71
70
|
logger.debug("Unique ID = #{@unique_id}")
|
72
71
|
end
|
73
72
|
|
74
73
|
# Create a sub_dir in the Tempdir (name is based on unique id)
|
75
|
-
def
|
76
|
-
logger.debug("GV Tempdir = #{@
|
77
|
-
FileUtils.mkdir_p(@
|
78
|
-
end
|
79
|
-
|
80
|
-
# Create the Tmp Dir and the create a soft link to it.
|
81
|
-
def create_soft_link_from_tmpdir_to_gv_dir
|
82
|
-
@gv_dir = File.join(GeneValidatorApp.public_dir, 'GeneValidator',
|
83
|
-
@unique_id)
|
84
|
-
logger.debug("Local GV dir = #{@gv_dir}")
|
85
|
-
FileUtils.ln_s "#{@gv_tmpdir}", "#{@gv_dir}"
|
74
|
+
def create_run_dir
|
75
|
+
logger.debug("GV Tempdir = #{@run_dir}")
|
76
|
+
FileUtils.mkdir_p(@run_dir)
|
86
77
|
end
|
87
78
|
|
88
79
|
# Validates the paramaters provided via the app.
|
@@ -127,13 +118,11 @@ module GeneValidatorApp
|
|
127
118
|
|
128
119
|
# Writes the input sequences to a file with the sub_dir in the temp_dir
|
129
120
|
def write_seq_to_file
|
130
|
-
@
|
131
|
-
logger.debug("Writing input seqs to: '#{@
|
121
|
+
@input_file = File.join(@run_dir, 'input_file.fa')
|
122
|
+
logger.debug("Writing input seqs to: '#{@input_file}'")
|
132
123
|
ensure_unix_line_ending
|
133
124
|
ensure_fasta_valid
|
134
|
-
File.open(@
|
135
|
-
f.write(@params[:seq])
|
136
|
-
end
|
125
|
+
File.open(@input_file, 'w+') { |f| f.write(@params[:seq]) }
|
137
126
|
assert_input_file_present
|
138
127
|
end
|
139
128
|
|
@@ -163,12 +152,10 @@ module GeneValidatorApp
|
|
163
152
|
@params[:seq] = sequence
|
164
153
|
end
|
165
154
|
|
166
|
-
# Asserts
|
167
|
-
# empty
|
155
|
+
# Asserts that the input file has been generated and is not empty
|
168
156
|
def assert_input_file_present
|
169
|
-
|
170
|
-
|
171
|
-
end
|
157
|
+
return if File.exist?(@input_file) && !File.zero?(@input_file)
|
158
|
+
fail 'GeneValidatorApp was unable to create the input file.'
|
172
159
|
end
|
173
160
|
|
174
161
|
# Returns 'blastp' if sequence contains amino acids or returns 'blastx'
|
@@ -191,21 +178,21 @@ module GeneValidatorApp
|
|
191
178
|
end
|
192
179
|
|
193
180
|
def run_gv
|
194
|
-
cmd = "genevalidator -v '#{@params[:validations].join(',
|
195
|
-
" -d #{@db} -n #{config[:num_threads]} #{@
|
181
|
+
cmd = "genevalidator -v '#{@params[:validations].join(',')}'" \
|
182
|
+
" -d #{@db} -n #{config[:num_threads]} #{@input_file}"
|
196
183
|
logger.debug("GV command: $ #{cmd}")
|
197
184
|
log_file = (logger.debug?) ? '' : "> #{@gv_log_file} 2>&1"
|
198
185
|
`#{cmd} #{log_file}`
|
199
186
|
end
|
200
187
|
|
201
188
|
def create_gv_log_file
|
202
|
-
@gv_log_file = File.join(@
|
189
|
+
@gv_log_file = File.join(@run_dir, 'log_file.txt')
|
203
190
|
logger.debug("Log file: #{@gv_log_file}")
|
204
191
|
end
|
205
192
|
|
206
193
|
# Assets whether the results file is produced by GeneValidator.
|
207
194
|
def assert_json_output_file_produced
|
208
|
-
@json_file = File.join(@
|
195
|
+
@json_file = File.join(@run_dir, 'input_file.fa.json')
|
209
196
|
return if File.exist?(@json_file)
|
210
197
|
fail 'GeneValidator did not produce the required output file.'
|
211
198
|
end
|
@@ -228,11 +215,11 @@ module GeneValidatorApp
|
|
228
215
|
end
|
229
216
|
|
230
217
|
def output_json_file_path
|
231
|
-
"#{@
|
218
|
+
"#{@input_file}.json"
|
232
219
|
end
|
233
220
|
|
234
221
|
def copy_json_folder
|
235
|
-
json_dir = File.join("#{@
|
222
|
+
json_dir = File.join("#{@input_file}.html", 'files/json', '/.')
|
236
223
|
web_dir_json = File.join(public_dir, 'web_files/json')
|
237
224
|
logger.debug("Moving JSON files from #{json_dir} to #{web_dir_json}")
|
238
225
|
FileUtils.cp_r(json_dir, web_dir_json)
|
@@ -9,4 +9,4 @@
|
|
9
9
|
<h2> Calculating...</h2>
|
10
10
|
<p class="results_link"> This may take some time. Please leave this page open.</p>
|
11
11
|
</div>
|
12
|
-
<footer><div class="container center-block"><p class="text-muted text-center">Please cite: "Dragan M<sup>‡</sup>, Moghul MI<sup>‡</sup>, Priyam A, Bustos C & Wurm Y
|
12
|
+
<footer><div class="container center-block"><p class="text-muted text-center">Please cite: <a href="http://bioinformatics.oxfordjournals.org/content/early/2016/01/18/bioinformatics.btw015">Dragan M<sup>‡</sup>, Moghul MI<sup>‡</sup>, Priyam A, Bustos C & Wurm Y. 2016. GeneValidator: identify problems with protein-coding gene predictions". <em>Bioinformatics</em>, doi: 10.1093/bioinformatics/btw015</a>.<br/>Developed at <a href="https://wurmlab.github.io" target="_blank">Wurm Lab</a>, <a href="http://www.sbcs.qmul.ac.uk" target="_blank">QMUL</a> with funding by <a href="http://www.bbsrc.ac.uk/home/home.aspx" target="_blank">BBSRC</a> and <a href="https://www.google-melange.com/gsoc/homepage/google/gsoc2013" target="_blank">Google Summer of Code 2013</a><br/>This page was created by <a href="https://github.com/wurmlab/genevalidator" target="_blank" >GeneValidator</a> v1.6.5</p></div></footer></body></html>
|
data/views/layout.slim
CHANGED
@@ -31,16 +31,14 @@ html lang="en"
|
|
31
31
|
.navbar-collapse.collapse.navbar-responsive-collapse
|
32
32
|
ul.nav.navbar-nav
|
33
33
|
li
|
34
|
-
a href="
|
34
|
+
a href="https://wurmlab.github.io/tools/genevalidator/" target="_blank" GeneValidator
|
35
35
|
li
|
36
|
-
a href="https://github.
|
37
|
-
li
|
38
|
-
a href="https://wurmlab.github.io/GeneValidatorApp-API" target="_blank" API
|
39
|
-
/! a href="#" Documentation
|
40
|
-
/! li
|
41
|
-
/! a href="#" Support
|
36
|
+
a href="https://wurmlab.github.io/tools/genevalidator/api" target="_blank" API
|
42
37
|
li
|
43
38
|
a href="https://wurmlab.github.io" target="_blank" Wurm Lab
|
39
|
+
li
|
40
|
+
a href="http://doi.org/10.1093/bioinformatics/btw015" target="_blank" Publication
|
41
|
+
|
44
42
|
ul.nav.navbar-nav.navbar-right
|
45
43
|
li
|
46
44
|
a.nav_github_icon href="https://github.com/wurmlab/genevalidatorapp" target="_blank"
|
@@ -55,10 +53,9 @@ html lang="en"
|
|
55
53
|
i.fa.fa-spinner.fa-5x.fa-spin
|
56
54
|
footer#footer
|
57
55
|
p.text-muted.text-center
|
58
|
-
| Please cite
|
59
|
-
|
60
|
-
|
61
|
-
| GeneValidator: identify problematic gene predictions"
|
56
|
+
| Please cite:
|
57
|
+
<a href="http://doi.org/10.1093/bioinformatics/btw015">Dragan M<sup>‡</sup>, Moghul MI<sup>‡</sup>, Priyam A, Bustos C & Wurm Y. 2016. GeneValidator: identify problematic gene predictions.
|
58
|
+
<em>Bioinformatics</em>, doi: 10.1093/bioinformatics/btw015</a>.
|
62
59
|
br
|
63
60
|
| Developed at
|
64
61
|
a href="https://wurmlab.github.io" target="_blank" Wurm Lab
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: genevalidatorapp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Monica Dragan
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2016-09-13 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: bundler
|
@@ -208,6 +208,7 @@ files:
|
|
208
208
|
- Rakefile
|
209
209
|
- bin/genevalidatorapp
|
210
210
|
- config.ru
|
211
|
+
- docker/Dockerfile
|
211
212
|
- genevalidatorapp.gemspec
|
212
213
|
- lib/genevalidatorapp.rb
|
213
214
|
- lib/genevalidatorapp/config.rb
|