-
Notifications
You must be signed in to change notification settings - Fork 1
/
check-recipe.html
366 lines (298 loc) · 21.4 KB
/
check-recipe.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>ggd check-recipe — GGD documentation</title>
<link rel="stylesheet" href="_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="_static/alabaster.css" type="text/css" />
<link rel="stylesheet" type="text/css" href="_static/style.css" />
<link rel="stylesheet" type="text/css" href="_static/font-awesome-4.7.0/css/font-awesome.min.css" />
<script id="documentation_options" data-url_root="./" src="_static/documentation_options.js"></script>
<script src="_static/jquery.js"></script>
<script src="_static/underscore.js"></script>
<script src="_static/doctools.js"></script>
<link rel="index" title="Index" href="genindex.html" />
<link rel="search" title="Search" href="search.html" />
<link rel="next" title="GGD meta-recipes" href="meta-recipes.html" />
<link rel="prev" title="ggd make-meta-recipe" href="make-metarecipe.html" />
<link href="https://fonts.googleapis.com/css?family=Lato|Raleway" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Inconsolata" rel="stylesheet">
<meta name="msapplication-TileColor" content="#ffffff">
<meta name="msapplication-TileImage" content="_static/ms-icon-144x144.png">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/selectize.js/0.12.6/css/selectize.bootstrap3.min.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/css/bootstrap.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/datatables/1.10.21/js/jquery.dataTables.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/selectize.js/0.12.6/js/standalone/selectize.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.bundle.min.js"></script>
</head><body>
<div class="document">
<div class="sphinxsidebar" role="navigation" aria-label="main navigation">
<div class="sphinxsidebarwrapper">
<p class="logo">
<a href="index.html">
<img class="logo" src="_static/logo/GoGetData_name_logo.png" alt="Logo"/>
</a>
</p>
<h3>Navigation</h3>
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="quick-start.html">GGD Quick Start</a></li>
<li class="toctree-l1"><a class="reference internal" href="using-ggd.html">Using GGD</a></li>
<li class="toctree-l1 current"><a class="reference internal" href="GGD-CLI.html">GGD Commands</a><ul class="current">
<li class="toctree-l2"><a class="reference internal" href="ggd-search.html">ggd search</a></li>
<li class="toctree-l2"><a class="reference internal" href="install.html">ggd install</a></li>
<li class="toctree-l2"><a class="reference internal" href="predict-path.html">ggd predict-path</a></li>
<li class="toctree-l2"><a class="reference internal" href="uninstall.html">ggd uninstall</a></li>
<li class="toctree-l2"><a class="reference internal" href="list.html">ggd list</a></li>
<li class="toctree-l2"><a class="reference internal" href="list-file.html">ggd get-files</a></li>
<li class="toctree-l2"><a class="reference internal" href="pkg-info.html">ggd pkg-info</a></li>
<li class="toctree-l2"><a class="reference internal" href="show-env.html">ggd show-env</a></li>
<li class="toctree-l2"><a class="reference internal" href="make-recipe.html">ggd make-recipe</a></li>
<li class="toctree-l2"><a class="reference internal" href="make-metarecipe.html">ggd make-meta-recipe</a></li>
<li class="toctree-l2 current"><a class="current reference internal" href="#">ggd check-recipe</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="meta-recipes.html">GGD meta-recipes</a></li>
<li class="toctree-l1"><a class="reference internal" href="contribute.html">Contribute</a></li>
<li class="toctree-l1"><a class="reference internal" href="private_recipes.html">Private Recipes</a></li>
<li class="toctree-l1"><a class="reference internal" href="workflows.html">Using GGD in Workflows</a></li>
<li class="toctree-l1"><a class="reference internal" href="recipes.html">Available Data Packages</a></li>
</ul>
<ul>
<li class="toctree-l1"><a href="https://github.com/gogetdata/ggd-recipes">ggd-recipes @ Github</a></li>
<li class="toctree-l1"><a href="https://github.com/gogetdata/ggd-cli">ggd-cli @ Github</a></li>
</ul>
<div id="searchbox" style="display: none" role="search">
<h3 id="searchlabel">Quick search</h3>
<div class="searchformwrapper">
<form class="search" action="search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" />
<input type="submit" value="Go" />
</form>
</div>
</div>
<script>$('#searchbox').show(0);</script>
</div>
</div>
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body" role="main">
<div class="section" id="ggd-check-recipe">
<span id="id1"></span><h1>ggd check-recipe<a class="headerlink" href="#ggd-check-recipe" title="Permalink to this headline">¶</a></h1>
<p>[<a class="reference internal" href="index.html#home-page"><span class="std std-ref">Click here to return to the home page</span></a>]</p>
<div class="section" id="check-recipe-is-used-to-validate-a-recipe-created-from-running-ggd-make-recipe">
<h2><cite>check-recipe</cite> is used to validate a recipe created from running <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">make-recipe</span></code><a class="headerlink" href="#check-recipe-is-used-to-validate-a-recipe-created-from-running-ggd-make-recipe" title="Permalink to this headline">¶</a></h2>
<p><code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code> is used to check a ggd recipe built by running <a class="reference internal" href="make-recipe.html#ggd-make-recipe"><span class="std std-ref">ggd make-recipe</span></a>. <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">make-recipe</span></code>
takes a bash script used to download and process data and turns it into a ggd data recipe. <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code> should
then be called to test the newly built ggd recipe.</p>
<p><code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code> is a part of the tool set used to create and contribute data packages to the ggd data repository.
For more information about using the ggd workflow to contribute to ggd see <a class="reference internal" href="contribute.html#make-data-packages"><span class="std std-ref">contribute</span></a>.</p>
</div>
<div class="section" id="using-ggd-check-recipe">
<h2>Using ggd check-recipe<a class="headerlink" href="#using-ggd-check-recipe" title="Permalink to this headline">¶</a></h2>
<p>Checking a newly built ggd recipe is easy using the <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code> tool.
Running <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span> <span class="pre">-h</span></code> will give you the following help message:</p>
<p>check-recipe arguments:</p>
<table class="docutils align-default">
<colgroup>
<col style="width: 22%" />
<col style="width: 78%" />
</colgroup>
<thead>
<tr class="row-odd"><th class="head"><p>ggd check-recipe</p></th>
<th class="head"><p>Convert a ggd recipe created from <cite>ggd make-recipe</cite> into a data package. Test
both ggd data recipe and data package</p></th>
</tr>
</thead>
<tbody>
<tr class="row-even"><td><p><code class="docutils literal notranslate"><span class="pre">-h</span></code>, <code class="docutils literal notranslate"><span class="pre">--help</span></code></p></td>
<td><p>show this help message and exit</p></td>
</tr>
<tr class="row-odd"><td><p><code class="docutils literal notranslate"><span class="pre">-d</span></code>, <code class="docutils literal notranslate"><span class="pre">--debug</span></code></p></td>
<td><p>(Optional) Set the stdout log level to debug</p></td>
</tr>
<tr class="row-even"><td><p><code class="docutils literal notranslate"><span class="pre">-du</span></code>,
<code class="docutils literal notranslate"><span class="pre">--dont_uninstall</span></code></p></td>
<td><p>(Optional) By default the newly installed local ggd
data package is uninstalled after the check has
finished. To bypass this uninstall step (to keep the
local package installed) set this flag “–
dont_uninstall”</p></td>
</tr>
<tr class="row-odd"><td><p><code class="docutils literal notranslate"><span class="pre">--id</span></code>,
<code class="docutils literal notranslate"><span class="pre">(meta-recipe</span> <span class="pre">ID)</span></code></p></td>
<td><p>If checking a meta-recipe the associated meta-recipe id needs to be supplied.
(Example: for a geo meta-recipe use something like –id GSE123) NOTE: GGD does
not try to correct the ID. Please provide the correct case sensitive ID.</p></td>
</tr>
<tr class="row-even"><td><p><code class="docutils literal notranslate"><span class="pre">recipe_path</span></code></p></td>
<td><p><strong>Required</strong> Path to recipe directory (can also be path to the .bz2)</p></td>
</tr>
</tbody>
</table>
<div class="section" id="additional-argument-explanation">
<h3>Additional argument explanation:<a class="headerlink" href="#additional-argument-explanation" title="Permalink to this headline">¶</a></h3>
<p>Required arguments:</p>
<ul class="simple">
<li><p><em>recipe_path:</em> The <code class="code docutils literal notranslate"><span class="pre">recipe_path</span></code> is a positional argument and represents the path the the directory/recipe created from
running <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">make-recipe</span></code>. This path is required, as it represents the recipe that will be tested and validated.</p></li>
</ul>
<p>Optional arguments:</p>
<ul class="simple">
<li><p><em>-d:</em> The <code class="code docutils literal notranslate"><span class="pre">-d</span></code> flag is used to provide additional output from running “check-recipe”. This is useful if the tests
fail and it is unclear why they have failed. The output can be overwhelming, so if it is not needed try not to set this
flag.</p></li>
<li><p><em>-du:</em> The <code class="code docutils literal notranslate"><span class="pre">-du</span></code> flag is used to tell <cite>check-recipe</cite> not to uninstall the data after it has finished testing the
recipe. In order to test a portion of the recipe, the recipe will be packaged into a data package and will be installed.
The default functionality for <cite>check-recipe</cite> is to uninstall that file once the tests have finished. If you would like
to keep the local data package installed add <code class="code docutils literal notranslate"><span class="pre">-du</span></code> to your <cite>check-recipe</cite> command.</p></li>
<li><dl class="simple">
<dt><em>id:</em> The <code class="code docutils literal notranslate"><span class="pre">--id</span></code> parameter is used to designate the ID to use when checking a meta-recipe. This ID is required in order</dt><dd><p>to check the meta-recipe. The ID represents a unique identifier that the meta-recipe can used to download data from the
database the meta-recipe is created for. The ID entered is based on an ID that can be used by the specific meta-recipe being
checked. NOTE: GGD does not try to fix IDs. They must be entered correctly including being
case sensitive with proper alphanumeric order.</p>
</dd>
</dl>
</li>
</ul>
<p>The only required argument is the <code class="code docutils literal notranslate"><span class="pre">recipe_path</span></code> and refers to the directory you would like <code class="docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code>
to check. When using <a class="reference internal" href="make-recipe.html#ggd-make-recipe"><span class="std std-ref">ggd make-recipe</span></a> to create a ggd recipe, make-recipe will
create a new directory with four new files. The recipe_path should be the path to the new directory created
from using <cite>ggd make-recipe</cite>.</p>
<blockquote>
<div><div class="admonition note">
<p class="admonition-title">Note</p>
<p>The <code class="code docutils literal notranslate"><span class="pre">--id</span></code> parameter is required if checking a meta-recipe</p>
</div>
</div></blockquote>
<p>Running <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span> <span class="pre"><recipe-path></span></code> will build, install, and test and validate the recipe to ensure the recipe works correctly.</p>
</div>
</div>
<div class="section" id="example">
<h2>Example<a class="headerlink" href="#example" title="Permalink to this headline">¶</a></h2>
<div class="section" id="an-example-of-creating-a-ggd-recipe-from-ggd-make-recipe-and-using-ggd-check-recipe-to-check-the-recipe">
<h3>1. An example of creating a ggd recipe from <code class="docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">make-recipe</span></code> and using <code class="docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code> to check the recipe<a class="headerlink" href="#an-example-of-creating-a-ggd-recipe-from-ggd-make-recipe-and-using-ggd-check-recipe-to-check-the-recipe" title="Permalink to this headline">¶</a></h3>
<blockquote>
<div><ul class="simple">
<li><p>get_data.sh (A bash script used to create a recipe with <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">make-recipe</span></code>)</p></li>
</ul>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="ch">#!/bin/sh</span>
<span class="nb">set</span> <span class="o">-</span><span class="n">eo</span> <span class="n">pipefail</span> <span class="o">-</span><span class="n">o</span> <span class="n">nounset</span>
<span class="n">wget</span> <span class="o">--</span><span class="n">quiet</span> <span class="o">--</span><span class="n">no</span><span class="o">-</span><span class="n">check</span><span class="o">-</span><span class="n">certificate</span> \
<span class="o">-</span><span class="n">O</span> <span class="n">hg19</span><span class="o">-</span><span class="n">phastcons</span><span class="o">-</span><span class="n">ucsc</span><span class="o">-</span><span class="n">v1</span><span class="o">.</span><span class="n">bw</span> \
<span class="n">http</span><span class="p">:</span><span class="o">//</span><span class="n">hgdownload</span><span class="o">.</span><span class="n">cse</span><span class="o">.</span><span class="n">ucsc</span><span class="o">.</span><span class="n">edu</span><span class="o">/</span><span class="n">goldenpath</span><span class="o">/</span><span class="n">hg19</span><span class="o">/</span><span class="n">phastCons100way</span><span class="o">/</span><span class="n">hg19</span><span class="o">.</span><span class="mi">100</span><span class="n">way</span><span class="o">.</span><span class="n">phastCons</span><span class="o">.</span><span class="n">bw</span>
</pre></div>
</div>
<ul class="simple">
<li><p>Using <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">make-recipe</span></code> to create a ggd recipe</p></li>
</ul>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span>$ ggd make-recipe \
-s Homo_sapiens \
-g hg19 \
--author mjc \
-pv 1 \
-dv 09-Feb-2014 \
-dp UCSC\
--summary 'phastCons scores for MSA of 99 genomes to hg19' \
-cb 0-based-inclusive \
-k phastCons \
-k conservation \
-n phastcons \
get_data.sh
</pre></div>
</div>
<ul class="simple">
<li><dl class="simple">
<dt>A new directory called <strong>hg19-phastcons-ucsc-v1</strong> is now present in the current working directory</dt><dd><ul>
<li><p>The <strong>hg19-phastcons-ucsc-v1</strong> directory contains four files: <strong>meta.yaml</strong>, <strong>post-link.sh</strong>, <strong>recipe.sh</strong>, and <strong>checksums_file.txt</strong></p></li>
<li><p>Lets say the path to <strong>hg19-phastcons-ucsc-v1</strong> is <code class="docutils literal notranslate"><span class="pre">/user/home/hg19-phastcons-ucsc-v1/</span></code></p></li>
</ul>
</dd>
</dl>
</li>
<li><p>Using <code class="code docutils literal notranslate"><span class="pre">ggd</span> <span class="pre">check-recipe</span></code> we will build, install, and test the new <strong>hg19-phastcons-ucsc-v1</strong> recipe</p></li>
</ul>
<div class="highlight-default notranslate"><div class="highlight"><pre><span></span>$ ggd check-recipe /user/home/hg19-phastcons-ucsc-v1/
No numpy version specified in conda_build_config.yaml. Falling back to default numpy value of 1.11
WARNING:conda_build.metadata:No numpy version specified in conda_build_config.yaml. Falling back to default numpy value of 1.11
INFO:conda_build.variants:Adding in variants from internal_defaults
INFO:conda_build.metadata:Attempting to finalize metadata for hg19-phastcons-ucsc-v1
INFO:conda_build.build:Packaging hg19-phastcons-ucsc-v1
INFO conda_build.build:build(1540): Packaging hg19-phastcons-ucsc-v1
INFO:conda_build.build:Packaging hg19-phastcons-ucsc-v1-1-0
INFO conda_build.build:bundle_conda(879): Packaging hg19-phastcons-ucsc-v1-1-0
No files or script found for output hg19-phastcons-ucsc-v1
WARNING:conda_build.build:No files or script found for output hg19-phastcons-ucsc-v1
WARNING conda_build.build:bundle_conda(959): No files or script found for output hg19-phastcons-ucsc-v1
Importing conda-verify failed. Please be sure to test your packages. conda install conda-verify to make this message go away.
WARNING:conda_build.build:Importing conda-verify failed. Please be sure to test your packages. conda install conda-verify to make this message go away.
WARNING conda_build.build:bundle_conda(1030): Importing conda-verify failed. Please be sure to test your packages. conda install conda-verify to make this message go away.
INFO:conda_build.variants:Adding in variants from /scratch/tmpn3m0b150/info/recipe/conda_build_config.yaml
INFO conda_build.variants:_combine_spec_dictionaries(189): Adding in variants from /scratch/local/tmpn3m0b150/info/recipe/conda_build_config.yaml
Collecting package metadata (current_repodata.json): ...working... Unable to retrieve repodata (response: 404) for https://conda.anaconda.org/ggd-genomics/linux-64/current_repodata.json
done
Solving environment: ...working... Could not run SAT solver through interface 'pycryptosat'.
done
initializing UnlinkLinkTransaction with
target_prefix: <conda root>
unlink_precs:
link_precs:
local::hg19-phastcons-ucsc-v1-1-0
## Package Plan ##
environment location: <conda root>
added / updated specs:
- conda=4.7.12
- hg19-phastcons-ucsc-v1
The following packages will be downloaded:
package | build
---------------------------|-----------------
hg19-phastcons-ucsc-v1-1 | 0 5 KB local
------------------------------------------------------------
Total: 5 KB
The following NEW packages will be INSTALLED:
hg19-phastcons-uc~ <conda root>/conda-bld/noarch::hg19-phastcons-ucsc-v1-1-0
Preparing transaction: ...working... done
Verifying transaction: ...working... done
Executing transaction: ...working... ===> LINKING PACKAGE: local::hg19-phastcons-ucsc-v1-1-0 <===
prefix=<conda root>
source=<conda root>/pkgs/hg19-phastcons-ucsc-v1-1-0
done
:ggd:check-recipe: modified files:
:: <conda root>/share/ggd/Homo_sapiens/hg19/hg19-phastcons-ucsc-v1/1/hg19-phastcons-ucsc-v1.bw
:ggd:check-recipe: > checking <conda root>/share/ggd/Homo_sapiens/hg19/hg19-phastcons-ucsc-v1/1/hg19-phastcons-ucsc-v1.bw
:ggd:check-recipe: Updating the list of final data files
:ggd:check-recipe: Updating md5sums for final data files
****************************
* Successful recipe check! *
****************************
**********************************
* Recipe ready for Pull Requests *
**********************************
:ggd:check-recipe: The --dont_uninstall flag was not set
Uninstalling the locally built ggd data package
:ggd:uninstall: Removing hg19-phastcons-ucsc-v1 version 1 file(s) from ggd recipe storage
:ggd:uninstall: Deleting 10 items of hg19-phastcons-ucsc-v1 version 1 from your conda root
:ggd:env: Removing the ggd_hg19_phastcons_ucsc_v1_dir environment variable
:ggd:env: Removing the ggd_hg19_phastcons_ucsc_v1_file environment variable
</pre></div>
</div>
<ul class="simple">
<li><p>If the recipe fails, a message will be displayed stating that it failed and (hopefully) why it failed.</p></li>
</ul>
</div></blockquote>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="clearer"></div>
</div>
<div class="footer">
©2016-2021, The GoGetData team.
|
<a href="_sources/check-recipe.rst.txt"
rel="nofollow">Page source</a>
</div>
</body>
</html>