-
-
Notifications
You must be signed in to change notification settings - Fork 214
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Async support #604
Comments
Hey everyone! 🌟 I've been diving deep into the community version of Supabase py and noticed a few areas that could use some tweaks. To address this, I've made some adjustments in my own repository, and I'd love for you to give it a try! Especially designed with FastAPI in mind, this revised version aims to enhance efficiency and compatibility.You know how Supabase js is crafted for frontend use, right? Well, I realized that the existing Supabase py is essentially a mirror of this js version, which doesn't quite fit the bill for Python web frameworks like FastAPI. In FastAPI, every request requires client instances, but I believe this approach isn't always necessary.My proposal? Let's introduce an 'auth clients dict' within the main async client. This way, we won't need to spawn excessive async clients. Instead, we can focus on auth clients, performing operations on Supabase through functions in the main async client (functions that will use the authclient with all the necessary info).I'm excited to collaborate and solve any bugs that might pop up. Let's work together to make the Supabase community even better! 😊 Feel free to join the discussion on GitHub and share your thoughts and suggestions! |
Hey @Atticuszz, These sounds like good suggestions - if you haven't done so already do you mind tagging @silentworks on the discussion? He's currently most up to date with the Supabase Python/Web Frameworks story and would be the best person to chat with to upstream any changes. Alternatively you can reach him on Discord too. Thanks! |
thanks,i'll do it right now 😄 |
We now have async support in the latest version 2.2.0 of supabase-py. You can use the async version in your code by doing: from supabase._async.client import AsyncClient as Client, create_client
async def create_supabase() -> Client:
return await create_client(url, key) |
i published supabase-py-async package
on pypi,if u wanna try ,pip install supabase-py-async!😊
The text was updated successfully, but these errors were encountered: