Skip to content

Commit

Permalink
version 1.17.1
Browse files Browse the repository at this point in the history
  • Loading branch information
seratch committed Apr 13, 2023
1 parent 7b4b082 commit f8c1b86
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 14 deletions.
23 changes: 11 additions & 12 deletions docs/api-docs/slack_bolt/oauth/internals.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ <h1 class="title">Module <code>slack_bolt.oauth.internals</code></h1>
<summary>
<span>Expand source code</span>
</summary>
<pre><code class="python">from logging import Logger
<pre><code class="python">import html
from logging import Logger
from typing import Optional
from typing import Union

Expand Down Expand Up @@ -60,7 +61,7 @@ <h1 class="title">Module <code>slack_bolt.oauth.internals</code></h1>
debug_message = f&#34;Handling an OAuth callback success (request: {request.query})&#34;
self._logger.debug(debug_message)

html = self._redirect_uri_page_renderer.render_success_page(
page_content = self._redirect_uri_page_renderer.render_success_page(
app_id=installation.app_id,
team_id=installation.team_id,
is_enterprise_install=installation.is_enterprise_install,
Expand All @@ -72,7 +73,7 @@ <h1 class="title">Module <code>slack_bolt.oauth.internals</code></h1>
&#34;Content-Type&#34;: &#34;text/html; charset=utf-8&#34;,
&#34;Set-Cookie&#34;: self._state_utils.build_set_cookie_for_deletion(),
},
body=html,
body=page_content,
)

def _build_callback_failure_response( # type: ignore
Expand All @@ -88,14 +89,13 @@ <h1 class="title">Module <code>slack_bolt.oauth.internals</code></h1>
# Adding a bit more details to the error code to help installers understand what&#39;s happening.
# This modification in the HTML page works only when developers use this built-in failure handler.
detailed_error = build_detailed_error(reason)
html = self._redirect_uri_page_renderer.render_failure_page(detailed_error)
return BoltResponse(
status=status,
headers={
&#34;Content-Type&#34;: &#34;text/html; charset=utf-8&#34;,
&#34;Set-Cookie&#34;: self._state_utils.build_set_cookie_for_deletion(),
},
body=html,
body=self._redirect_uri_page_renderer.render_failure_page(detailed_error),
)


Expand All @@ -113,7 +113,7 @@ <h1 class="title">Module <code>slack_bolt.oauth.internals</code></h1>
&lt;/head&gt;
&lt;body&gt;
&lt;h2&gt;Slack App Installation&lt;/h2&gt;
&lt;p&gt;&lt;a href=&#34;{url}&#34;&gt;&lt;img alt=&#34;&#34;Add to Slack&#34;&#34; height=&#34;40&#34; width=&#34;139&#34; src=&#34;https://platform.slack-edge.com/img/add_to_slack.png&#34; srcset=&#34;https://platform.slack-edge.com/img/add_to_slack.png 1x, https://platform.slack-edge.com/img/add_to_slack@2x.png 2x&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;{html.escape(url)}&#34;&gt;&lt;img alt=&#34;&#34;Add to Slack&#34;&#34; height=&#34;40&#34; width=&#34;139&#34; src=&#34;https://platform.slack-edge.com/img/add_to_slack.png&#34; srcset=&#34;https://platform.slack-edge.com/img/add_to_slack.png 1x, https://platform.slack-edge.com/img/add_to_slack@2x.png 2x&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;/body&gt;
&lt;/html&gt;
&#34;&#34;&#34; # noqa: E501
Expand Down Expand Up @@ -170,7 +170,7 @@ <h1 class="title">Module <code>slack_bolt.oauth.internals</code></h1>
elif reason == &#34;storage_error&#34;:
return f&#34;{reason}: The app&#39;s server encountered an issue. Contact the app developer.&#34;
else:
return f&#34;{reason}: This error code is returned from Slack. Refer to the documents for details.&#34;</code></pre>
return f&#34;{html.escape(reason)}: This error code is returned from Slack. Refer to the documents for details.&#34;</code></pre>
</details>
</section>
<section>
Expand Down Expand Up @@ -203,7 +203,7 @@ <h2 class="section-title" id="header-functions">Functions</h2>
elif reason == &#34;storage_error&#34;:
return f&#34;{reason}: The app&#39;s server encountered an issue. Contact the app developer.&#34;
else:
return f&#34;{reason}: This error code is returned from Slack. Refer to the documents for details.&#34;</code></pre>
return f&#34;{html.escape(reason)}: This error code is returned from Slack. Refer to the documents for details.&#34;</code></pre>
</details>
</dd>
<dt id="slack_bolt.oauth.internals.get_or_create_default_installation_store"><code class="name flex">
Expand Down Expand Up @@ -292,7 +292,7 @@ <h2 class="section-title" id="header-classes">Classes</h2>
debug_message = f&#34;Handling an OAuth callback success (request: {request.query})&#34;
self._logger.debug(debug_message)

html = self._redirect_uri_page_renderer.render_success_page(
page_content = self._redirect_uri_page_renderer.render_success_page(
app_id=installation.app_id,
team_id=installation.team_id,
is_enterprise_install=installation.is_enterprise_install,
Expand All @@ -304,7 +304,7 @@ <h2 class="section-title" id="header-classes">Classes</h2>
&#34;Content-Type&#34;: &#34;text/html; charset=utf-8&#34;,
&#34;Set-Cookie&#34;: self._state_utils.build_set_cookie_for_deletion(),
},
body=html,
body=page_content,
)

def _build_callback_failure_response( # type: ignore
Expand All @@ -320,14 +320,13 @@ <h2 class="section-title" id="header-classes">Classes</h2>
# Adding a bit more details to the error code to help installers understand what&#39;s happening.
# This modification in the HTML page works only when developers use this built-in failure handler.
detailed_error = build_detailed_error(reason)
html = self._redirect_uri_page_renderer.render_failure_page(detailed_error)
return BoltResponse(
status=status,
headers={
&#34;Content-Type&#34;: &#34;text/html; charset=utf-8&#34;,
&#34;Set-Cookie&#34;: self._state_utils.build_set_cookie_for_deletion(),
},
body=html,
body=self._redirect_uri_page_renderer.render_failure_page(detailed_error),
)</code></pre>
</details>
</dd>
Expand Down
2 changes: 1 addition & 1 deletion docs/api-docs/slack_bolt/version.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ <h1 class="title">Module <code>slack_bolt.version</code></h1>
<span>Expand source code</span>
</summary>
<pre><code class="python">&#34;&#34;&#34;Check the latest version at https://pypi.org/project/slack-bolt/&#34;&#34;&#34;
__version__ = &#34;1.17.0&#34;</code></pre>
__version__ = &#34;1.17.1&#34;</code></pre>
</details>
</section>
<section>
Expand Down
2 changes: 1 addition & 1 deletion slack_bolt/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""Check the latest version at https://pypi.org/project/slack-bolt/"""
__version__ = "1.17.0"
__version__ = "1.17.1"

0 comments on commit f8c1b86

Please sign in to comment.