Skip to content

Commit

Permalink
Deploying to gh-pages from @ fb49f2f 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
vsoch committed Jan 29, 2024
1 parent 87cce47 commit b2d86fb
Show file tree
Hide file tree
Showing 33 changed files with 64 additions and 37 deletions.
2 changes: 1 addition & 1 deletion _modules/functools.html
Original file line number Diff line number Diff line change
Expand Up @@ -1324,7 +1324,7 @@ <h1 id="modules-functools--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ <h1 id="modules-index--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/auth.html
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ <h1 id="modules-oras-auth--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/client.html
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ <h1 id="modules-oras-client--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/container.html
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ <h1 id="modules-oras-container--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/decorator.html
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ <h1 id="modules-oras-decorator--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/defaults.html
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@ <h1 id="modules-oras-defaults--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/logger.html
Original file line number Diff line number Diff line change
Expand Up @@ -675,7 +675,7 @@ <h1 id="modules-oras-logger--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/main/login.html
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ <h1 id="modules-oras-main-login--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/oci.html
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ <h1 id="modules-oras-oci--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
25 changes: 20 additions & 5 deletions _modules/oras/provider.html
Original file line number Diff line number Diff line change
Expand Up @@ -1092,8 +1092,10 @@ <h1 id="modules-oras-provider--page-root">

<span class="c1"># Config is just another layer blob!</span>
<span class="n">logger</span><span class="o">.</span><span class="n">debug</span><span class="p">(</span><span class="sa">f</span><span class="s2">"Preparing config </span><span class="si">{</span><span class="n">conf</span><span class="si">}</span><span class="s2">"</span><span class="p">)</span>
<span class="k">with</span> <span class="n">temporary_empty_config</span><span class="p">()</span> <span class="k">if</span> <span class="n">config_file</span> <span class="ow">is</span> <span class="kc">None</span> <span class="k">else</span> <span class="n">nullcontext</span><span class="p">(</span>
<span class="n">config_file</span>
<span class="k">with</span> <span class="p">(</span>
<span class="n">temporary_empty_config</span><span class="p">()</span>
<span class="k">if</span> <span class="n">config_file</span> <span class="ow">is</span> <span class="kc">None</span>
<span class="k">else</span> <span class="n">nullcontext</span><span class="p">(</span><span class="n">config_file</span><span class="p">)</span>
<span class="p">)</span> <span class="k">as</span> <span class="n">config_file</span><span class="p">:</span>
<span class="n">response</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">upload_blob</span><span class="p">(</span><span class="n">config_file</span><span class="p">,</span> <span class="n">container</span><span class="p">,</span> <span class="n">conf</span><span class="p">)</span>

Expand All @@ -1118,6 +1120,8 @@ <h1 id="modules-oras-provider--page-root">
<span class="sd"> :type allowed_media_type: list or None</span>
<span class="sd"> :param overwrite: if output file exists, overwrite</span>
<span class="sd"> :type overwrite: bool</span>
<span class="sd"> :param refresh_headers: if true, headers are refreshed when fetching manifests</span>
<span class="sd"> :type refresh_headers: bool</span>
<span class="sd"> :param manifest_config_ref: save manifest config to this file</span>
<span class="sd"> :type manifest_config_ref: str</span>
<span class="sd"> :param outdir: output directory path</span>
Expand All @@ -1126,9 +1130,12 @@ <h1 id="modules-oras-provider--page-root">
<span class="sd"> :type target: str</span>
<span class="sd"> """</span>
<span class="n">allowed_media_type</span> <span class="o">=</span> <span class="n">kwargs</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">"allowed_media_type"</span><span class="p">)</span>
<span class="n">refresh_headers</span> <span class="o">=</span> <span class="n">kwargs</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">"refresh_headers"</span><span class="p">)</span>
<span class="k">if</span> <span class="n">refresh_headers</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span>
<span class="n">refresh_headers</span> <span class="o">=</span> <span class="kc">True</span>
<span class="n">container</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">get_container</span><span class="p">(</span><span class="n">kwargs</span><span class="p">[</span><span class="s2">"target"</span><span class="p">])</span>
<span class="bp">self</span><span class="o">.</span><span class="n">load_configs</span><span class="p">(</span><span class="n">container</span><span class="p">,</span> <span class="n">configs</span><span class="o">=</span><span class="n">kwargs</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">"config_path"</span><span class="p">))</span>
<span class="n">manifest</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">get_manifest</span><span class="p">(</span><span class="n">container</span><span class="p">,</span> <span class="n">allowed_media_type</span><span class="p">)</span>
<span class="n">manifest</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">get_manifest</span><span class="p">(</span><span class="n">container</span><span class="p">,</span> <span class="n">allowed_media_type</span><span class="p">,</span> <span class="n">refresh_headers</span><span class="p">)</span>
<span class="n">outdir</span> <span class="o">=</span> <span class="n">kwargs</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">"outdir"</span><span class="p">)</span> <span class="ow">or</span> <span class="n">oras</span><span class="o">.</span><span class="n">utils</span><span class="o">.</span><span class="n">get_tmpdir</span><span class="p">()</span>
<span class="n">overwrite</span> <span class="o">=</span> <span class="n">kwargs</span><span class="o">.</span><span class="n">get</span><span class="p">(</span><span class="s2">"overwrite"</span><span class="p">,</span> <span class="kc">True</span><span class="p">)</span>

Expand Down Expand Up @@ -1169,7 +1176,10 @@ <h1 id="modules-oras-provider--page-root">

<span class="nd">@decorator</span><span class="o">.</span><span class="n">ensure_container</span>
<span class="k">def</span> <span class="nf">get_manifest</span><span class="p">(</span>
<span class="bp">self</span><span class="p">,</span> <span class="n">container</span><span class="p">:</span> <span class="n">container_type</span><span class="p">,</span> <span class="n">allowed_media_type</span><span class="p">:</span> <span class="n">Optional</span><span class="p">[</span><span class="nb">list</span><span class="p">]</span> <span class="o">=</span> <span class="kc">None</span>
<span class="bp">self</span><span class="p">,</span>
<span class="n">container</span><span class="p">:</span> <span class="n">container_type</span><span class="p">,</span>
<span class="n">allowed_media_type</span><span class="p">:</span> <span class="n">Optional</span><span class="p">[</span><span class="nb">list</span><span class="p">]</span> <span class="o">=</span> <span class="kc">None</span><span class="p">,</span>
<span class="n">refresh_headers</span><span class="p">:</span> <span class="nb">bool</span> <span class="o">=</span> <span class="kc">True</span><span class="p">,</span>
<span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">dict</span><span class="p">:</span>
<span class="w"> </span><span class="sd">"""</span>
<span class="sd"> Retrieve a manifest for a package.</span>
Expand All @@ -1178,11 +1188,16 @@ <h1 id="modules-oras-provider--page-root">
<span class="sd"> :type container: oras.container.Container or str</span>
<span class="sd"> :param allowed_media_type: one or more allowed media types</span>
<span class="sd"> :type allowed_media_type: str</span>
<span class="sd"> :param refresh_headers: if true, headers are refreshed</span>
<span class="sd"> :type refresh_headers: bool</span>
<span class="sd"> """</span>
<span class="k">if</span> <span class="ow">not</span> <span class="n">allowed_media_type</span><span class="p">:</span>
<span class="n">allowed_media_type</span> <span class="o">=</span> <span class="p">[</span><span class="n">oras</span><span class="o">.</span><span class="n">defaults</span><span class="o">.</span><span class="n">default_manifest_media_type</span><span class="p">]</span>
<span class="n">headers</span> <span class="o">=</span> <span class="p">{</span><span class="s2">"Accept"</span><span class="p">:</span> <span class="s2">";"</span><span class="o">.</span><span class="n">join</span><span class="p">(</span><span class="n">allowed_media_type</span><span class="p">)}</span>

<span class="k">if</span> <span class="ow">not</span> <span class="n">refresh_headers</span><span class="p">:</span>
<span class="n">headers</span><span class="o">.</span><span class="n">update</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">headers</span><span class="p">)</span>

<span class="n">get_manifest</span> <span class="o">=</span> <span class="sa">f</span><span class="s2">"</span><span class="si">{</span><span class="bp">self</span><span class="o">.</span><span class="n">prefix</span><span class="si">}</span><span class="s2">://</span><span class="si">{</span><span class="n">container</span><span class="o">.</span><span class="n">manifest_url</span><span class="p">()</span><span class="si">}</span><span class="s2">"</span> <span class="c1"># type: ignore</span>
<span class="n">response</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">do_request</span><span class="p">(</span><span class="n">get_manifest</span><span class="p">,</span> <span class="s2">"GET"</span><span class="p">,</span> <span class="n">headers</span><span class="o">=</span><span class="n">headers</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">_check_200_response</span><span class="p">(</span><span class="n">response</span><span class="p">)</span>
Expand Down Expand Up @@ -1396,7 +1411,7 @@ <h1 id="modules-oras-provider--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/tests/test_oras.html
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ <h1 id="modules-oras-tests-test-oras--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/tests/test_provider.html
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,7 @@ <h1 id="modules-oras-tests-test-provider--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/tests/test_utils.html
Original file line number Diff line number Diff line change
Expand Up @@ -471,7 +471,7 @@ <h1 id="modules-oras-tests-test-utils--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/utils/fileio.html
Original file line number Diff line number Diff line change
Expand Up @@ -749,7 +749,7 @@ <h1 id="modules-oras-utils-fileio--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion _modules/oras/utils/request.html
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ <h1 id="modules-oras-utils-request--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion about/license.html
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ <h1 id="about-license--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion contributing.html
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ <h2 id="pull-request-process">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion genindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -1771,7 +1771,7 @@ <h2 id="Y">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion getting_started/developer-guide.html
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,7 @@ <h3 id="docstrings">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion getting_started/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -498,7 +498,7 @@ <h1 id="getting-started-index--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion getting_started/installation.html
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ <h2 id="docker-container">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion getting_started/user-guide.html
Original file line number Diff line number Diff line change
Expand Up @@ -1577,7 +1577,7 @@ <h2 id="custom-clients">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ <h1 id="index--page-root">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion py-modindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -632,7 +632,7 @@ <h1>
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion search.html
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ <h1 id="search-documentation">
© Copyright 2023, Oras Python Developers.
</div>
Last updated on
Jan 26, 2024.
Jan 29, 2024.
<br/>
Created using
<a href="http://www.sphinx-doc.org/">
Expand Down
2 changes: 1 addition & 1 deletion searchindex.js

Large diffs are not rendered by default.

Loading

0 comments on commit b2d86fb

Please sign in to comment.