mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 03:34:10 +00:00
refactor: add black formatting
This commit is contained in:
parent
b87d630b0a
commit
4905929de3
156 changed files with 19723 additions and 10869 deletions
11
ui/auth.py
11
ui/auth.py
|
@ -6,9 +6,11 @@ Uses supabase passwordless auth: https://supabase.com/docs/reference/python/auth
|
|||
Remember to set your redirect url to 8501 (streamlit default).
|
||||
"""
|
||||
import logging
|
||||
|
||||
logging.basicConfig(level=logging.DEBUG)
|
||||
import streamlit as st
|
||||
from dotenv import load_dotenv
|
||||
|
||||
load_dotenv()
|
||||
import os
|
||||
from supabase import create_client, Client
|
||||
|
@ -20,14 +22,13 @@ supabase: Client = create_client(url, key)
|
|||
|
||||
|
||||
def sign_in_with_otp(email: str, redirect_url: str):
|
||||
data = supabase.auth.sign_in_with_otp({"email": email,
|
||||
"options": {
|
||||
"email_redirect_to": redirect_url
|
||||
}})
|
||||
data = supabase.auth.sign_in_with_otp(
|
||||
{"email": email, "options": {"email_redirect_to": redirect_url}}
|
||||
)
|
||||
print(f"data: {data}")
|
||||
# Redirect to Supabase UI with the return data
|
||||
st.write(f"Please check your email for a login link!")
|
||||
|
||||
|
||||
|
||||
# Create the Streamlit app
|
||||
def auth_page(redirect_url: str):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue