Coder Social home page Coder Social logo

Program won't exit about supabase-dart HOT 4 CLOSED

supabase avatar supabase commented on September 23, 2024
Program won't exit

from supabase-dart.

Comments (4)

GZGavinZhao avatar GZGavinZhao commented on September 23, 2024 2

@phamhieu Yes this resolves the problem. Thank you for the help! We should probably add this info somewhere in our docs, in case other people get stuck on this.

from supabase-dart.

GZGavinZhao avatar GZGavinZhao commented on September 23, 2024 1

Sorry I was being unclear. My point is, say you're in a terminal. The expected behavior should be something like this:

$ dart run
Logging in...
Logged in, uid: 8ee21112-d3df-4cb3-b54c-c8326ab11b57
Got some data...
$

The program ends and you can execute something else now. However, what happens to me is:

$ dart run
Logging in...
Logged in, uid: 8ee21112-d3df-4cb3-b54c-c8326ab11b57
Got some data...
     <- cursor blinking here

The program just keeps running, even though every line of written code has finished executing.

from supabase-dart.

phamhieu avatar phamhieu commented on September 23, 2024

It will remain in this state forever.

Hi @GZGavinZhao, I'm not sure what do you want to archive. The code result seems correct to me.

from supabase-dart.

phamhieu avatar phamhieu commented on September 23, 2024

Thanks @GZGavinZhao, can you try again with supabase-dart latest version. You will also need to add this to the end of your code block

await client.auth.signOut();
print('Logged out');

As default, supabase-dart will manage user session and auto refresh it. So the thread will not exit until a user logout. Let me know if you are still facing the problem with latest version.

from supabase-dart.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.