Skip to content

Commit

Permalink
Update interface
Browse files Browse the repository at this point in the history
  • Loading branch information
ross-spencer committed Nov 20, 2024
1 parent 0ea4d03 commit f2d7541
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 24 deletions.
42 changes: 21 additions & 21 deletions docs/simple_sign/sign.html
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ <h1 class="title">Module <code>src.simple_sign.sign</code></h1>
raise NotImplementedError(&#34;reading staked values is not yet implemented&#34;)


def signature_belongs_to_staked_pool(
def signature_in_staked_pool(
pkey: str, token_policy_id: str, min_stake: int
) -&gt; bool:
&#34;&#34;&#34;Validate whether the signing key belongs to a someone who has
Expand Down Expand Up @@ -387,25 +387,6 @@ <h2 class="section-title" id="header-functions">Functions</h2>
return pyc.sign(data, skey)</code></pre>
</details>
</dd>
<dt id="src.simple_sign.sign.signature_belongs_to_staked_pool"><code class="name flex">
<span>def <span class="ident">signature_belongs_to_staked_pool</span></span>(<span>pkey: str, token_policy_id: str, min_stake: int) ‑> bool</span>
</code></dt>
<dd>
<div class="desc"><p>Validate whether the signing key belongs to a someone who has
enough stake in a given token.</p></div>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def signature_belongs_to_staked_pool(
pkey: str, token_policy_id: str, min_stake: int
) -&gt; bool:
&#34;&#34;&#34;Validate whether the signing key belongs to a someone who has
enough stake in a given token.
&#34;&#34;&#34;
raise NotImplementedError(&#34;reading staked values is not yet implemented&#34;)</code></pre>
</details>
</dd>
<dt id="src.simple_sign.sign.signature_in_constitution_config"><code class="name flex">
<span>def <span class="ident">signature_in_constitution_config</span></span>(<span>pkey: str) ‑> bool</span>
</code></dt>
Expand Down Expand Up @@ -488,6 +469,25 @@ <h2 class="section-title" id="header-functions">Functions</h2>
raise NotImplementedError(&#34;reading from license pool is not yet implemented&#34;)</code></pre>
</details>
</dd>
<dt id="src.simple_sign.sign.signature_in_staked_pool"><code class="name flex">
<span>def <span class="ident">signature_in_staked_pool</span></span>(<span>pkey: str, token_policy_id: str, min_stake: int) ‑> bool</span>
</code></dt>
<dd>
<div class="desc"><p>Validate whether the signing key belongs to a someone who has
enough stake in a given token.</p></div>
<details class="source">
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">def signature_in_staked_pool(
pkey: str, token_policy_id: str, min_stake: int
) -&gt; bool:
&#34;&#34;&#34;Validate whether the signing key belongs to a someone who has
enough stake in a given token.
&#34;&#34;&#34;
raise NotImplementedError(&#34;reading staked values is not yet implemented&#34;)</code></pre>
</details>
</dd>
<dt id="src.simple_sign.sign.signing_handler"><code class="name flex">
<span>def <span class="ident">signing_handler</span></span>(<span>data: str, signing_key: str) ‑> str</span>
</code></dt>
Expand Down Expand Up @@ -590,11 +590,11 @@ <h1>Index</h1>
<li><code><a title="src.simple_sign.sign.retrieve_aliased" href="#src.simple_sign.sign.retrieve_aliased">retrieve_aliased</a></code></li>
<li><code><a title="src.simple_sign.sign.retrieve_env_notaries" href="#src.simple_sign.sign.retrieve_env_notaries">retrieve_env_notaries</a></code></li>
<li><code><a title="src.simple_sign.sign.sign_with_key" href="#src.simple_sign.sign.sign_with_key">sign_with_key</a></code></li>
<li><code><a title="src.simple_sign.sign.signature_belongs_to_staked_pool" href="#src.simple_sign.sign.signature_belongs_to_staked_pool">signature_belongs_to_staked_pool</a></code></li>
<li><code><a title="src.simple_sign.sign.signature_in_constitution_config" href="#src.simple_sign.sign.signature_in_constitution_config">signature_in_constitution_config</a></code></li>
<li><code><a title="src.simple_sign.sign.signature_in_constitution_datum_utxo" href="#src.simple_sign.sign.signature_in_constitution_datum_utxo">signature_in_constitution_datum_utxo</a></code></li>
<li><code><a title="src.simple_sign.sign.signature_in_dapp_environment" href="#src.simple_sign.sign.signature_in_dapp_environment">signature_in_dapp_environment</a></code></li>
<li><code><a title="src.simple_sign.sign.signature_in_license_pool" href="#src.simple_sign.sign.signature_in_license_pool">signature_in_license_pool</a></code></li>
<li><code><a title="src.simple_sign.sign.signature_in_staked_pool" href="#src.simple_sign.sign.signature_in_staked_pool">signature_in_staked_pool</a></code></li>
<li><code><a title="src.simple_sign.sign.signing_handler" href="#src.simple_sign.sign.signing_handler">signing_handler</a></code></li>
<li><code><a title="src.simple_sign.sign.verify_handler" href="#src.simple_sign.sign.verify_handler">verify_handler</a></code></li>
<li><code><a title="src.simple_sign.sign.verify_signature" href="#src.simple_sign.sign.verify_signature">verify_signature</a></code></li>
Expand Down
4 changes: 1 addition & 3 deletions src/simple_sign/sign.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,7 @@ def retrieve_aliased(pkey: str) -> str:
raise NotImplementedError("reading staked values is not yet implemented")


def signature_belongs_to_staked_pool(
pkey: str, token_policy_id: str, min_stake: int
) -> bool:
def signature_in_staked_pool(pkey: str, token_policy_id: str, min_stake: int) -> bool:
"""Validate whether the signing key belongs to a someone who has
enough stake in a given token.
"""
Expand Down

0 comments on commit f2d7541

Please sign in to comment.