Skip to content
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

What "Already logged in" actually mean? #222

Open
DumahBrazorf opened this issue Dec 29, 2022 · 3 comments
Open

What "Already logged in" actually mean? #222

DumahBrazorf opened this issue Dec 29, 2022 · 3 comments

Comments

@DumahBrazorf
Copy link

DumahBrazorf commented Dec 29, 2022

Hi,
I have multiple pcs connecting to one account. Every pc save its session token to avoid loggin in every time. If the token expires there's a new login.
There's some pcs that many times got an "Already logged in" error message when issuing MegaApiClient.Login(thetokenpreviouslysaved). What it means? What should i do o have done before to avoid this error?
Maybe more pcs are accessing the account in that precise moment?
Thanks.

@gpailler
Copy link
Owner

gpailler commented Jan 9, 2023

I never saw this error. Do you call the Logout() method in your code after a session?

@DumahBrazorf
Copy link
Author

Mmm, i don't.
I didn't do it thinking it would have flooded the server with too many logins...
Let me change something in my code...

@DumahBrazorf
Copy link
Author

DumahBrazorf commented Jan 11, 2023

Ok i can't logout or the sessionId will be useless (badsessionid at the next login with masterkey and sessionId) and then i have to login with username and password. If you login too much often with user/pw mega will lock you out.

So "Already logged in" probably mean i'm already using that masterkey+sessionId and doing something with another instance.
I have to check my code to ensure the upload function is not called twice or more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@gpailler @DumahBrazorf and others