chore: bump ruff (#1085)
This commit is contained in:
parent
6f43d1f170
commit
9301924f44
3 changed files with 56 additions and 57 deletions
|
|
@ -89,7 +89,7 @@ class SimpleOAuthProvider(OAuthAuthorizationServerProvider):
|
|||
}
|
||||
|
||||
# Build simple login URL that points to login page
|
||||
auth_url = f"{self.auth_callback_url}" f"?state={state}" f"&client_id={client.client_id}"
|
||||
auth_url = f"{self.auth_callback_url}?state={state}&client_id={client.client_id}"
|
||||
|
||||
return auth_url
|
||||
|
||||
|
|
@ -117,7 +117,7 @@ class SimpleOAuthProvider(OAuthAuthorizationServerProvider):
|
|||
<p><strong>Username:</strong> demo_user<br>
|
||||
<strong>Password:</strong> demo_password</p>
|
||||
|
||||
<form action="{self.server_url.rstrip('/')}/login/callback" method="post">
|
||||
<form action="{self.server_url.rstrip("/")}/login/callback" method="post">
|
||||
<input type="hidden" name="state" value="{state}">
|
||||
<div class="form-group">
|
||||
<label>Username:</label>
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ def main(
|
|||
for i in range(count):
|
||||
await ctx.session.send_log_message(
|
||||
level="info",
|
||||
data=f"Notification {i+1}/{count} from caller: {caller}",
|
||||
data=f"Notification {i + 1}/{count} from caller: {caller}",
|
||||
logger="notification_stream",
|
||||
related_request_id=ctx.request_id,
|
||||
)
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ def main(
|
|||
for i in range(count):
|
||||
# Include more detailed message for resumability demonstration
|
||||
notification_msg = (
|
||||
f"[{i+1}/{count}] Event from '{caller}' - "
|
||||
f"[{i + 1}/{count}] Event from '{caller}' - "
|
||||
f"Use Last-Event-ID to resume if disconnected"
|
||||
)
|
||||
await ctx.session.send_log_message(
|
||||
|
|
@ -69,7 +69,7 @@ def main(
|
|||
# - nowhere (if GET request isn't supported)
|
||||
related_request_id=ctx.request_id,
|
||||
)
|
||||
logger.debug(f"Sent notification {i+1}/{count} for caller: {caller}")
|
||||
logger.debug(f"Sent notification {i + 1}/{count} for caller: {caller}")
|
||||
if i < count - 1: # Don't wait after the last notification
|
||||
await anyio.sleep(interval)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue