Invalid login credentials , 400 bad request I use...
# help
b
Invalid login credentials , 400 bad request I use supabase auth to create users using service key based supabase.js client to sign up users, when users are signed up they get automatically signed in. I have disabled email confirmation in supabase studio dashboard for development purpose. After signup and autologin I logout then if i try to login again with correct credentials it still shows invalid login credentials. I tried and checked the network request for any trailing or unnecessary spaces, the login credentials are correct sent correctly. So can any one help me find what the issue is ? what could be the possible reasons i am getting that invalid login credentials error ?
n
Hello @BAN! This thread has been automatically created from your message in #843999948717555735 a few seconds ago. We have already mentioned the @User so that they can see your message and help you as soon as possible! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ``...`` menu) and select "Leave Thread" to unsubscribe from future updates. Want to change the title? Use the ``/title`` command! We have solved your problem? Click the button below to archive it.
🆕 Invalid login credentials
s
Try the process again with a new user and see if you get the same results. If you do, let me know the steps you take to reproduce this.
n
Invalid login credentials
b
I have tried creating new users and the same issue exists. Is it because of using role? i already have the new users assigned a student role and granted login permission etc. This issue exists only in this single project ..so I guess its not a bug in supabase, most probably i did something wrong. Does postgres roles have something to do with this invalid login credentials issue ? How can i try to reset service_role permission to default ? I just want to try that .
@silentworks I have tried to create a user and login in a newly created fresh supabase project in my personal account and it still throws Invalid login credentials
all the credentials logged in network log in my app shows correct credentials
@silentworks just try and create a new project i used asian server mumbai server for my project created a new project, used supabase.js client and anon key to create user, user is created in supabase auth but when i login i get invalid login credentials . This is how you can try to reproduce this issue. pls do respond cause im kind of frustrated so much, there is no way to find what is wrong ... what the problem is and all we get is a single error message.
s
Does this only happen when you create projects in this region?
Can you also share some code of how you are creating the user and also trying to log in?
b
I guess yes, both new and old project are in this region
Excatly same as in the docs
nothing custom
s
I don't know what this means
You would have to write it in a js file or in a project
b
ys
s
Try creating in another region and let me know if the issue persists.
b
Copy code
js
export const supabase = createClient(supabaseUrl, supabaseAnonKey);

 const { user, error: createUserError } = await supaTest.auth.signUp({
        email: data.email,
        password: data.phone,
      });

const { error } = await signIn({ email, password });
we write this in js file in project
ok i'll do that
s
You have
supaTest
as your variable name when calling
signUp
but you created it as
supabase
above, was that a typo?
b
supaTest is the client i created instead of using
supabase
how is that meant to not work while all other api are working with
supaTest
I also have exported supaTest client
Login is working fine in other region
s
Ok open a support ticket and someone from the backend team will have a look into this https://app.supabase.io/support/new
b
ok
s
Also sorry about the delay in my responses, we work in different time zones and had a major outage last night due to DNS issues
b
Ok
Ok I didnt know that .. anyway its fine , just help us with this issue
Its just that we have all our database and other parts of product ready, and we had that login working earlier.. but now it seems to have this issue
s
So sorry to hear that, let me know when you open the support ticket and I will ping someone in the backend team right away
b
I have already contacted them and they have contacted me by mail i guess the ticket is already up
s
Ok let me go and find it and get someone to look into it
b
ok
s
Ah I can see Egor is already on it.
b
ok
6 Views