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

Feature Request: Change how auto-login works #1063

Closed
Griatch opened this Issue Sep 14, 2016 · 6 comments

Comments

3 participants
@Griatch
Member

Griatch commented Sep 14, 2016

Brief summary of issue / Description of requested feature:

Currently the auto-login feature is asymmetric:

  1. Logging in to the website logs the Player in to both website and webclient
  2. Logging out of the website logs the Player out of both website and webclient
  3. Logging in to weclient logs the Player in to both website and webclient
  4. Logging out from the webclient logs the Player out of only the webclient

Case 4. should behave as 2.

Steps to reproduce the issue / Reasons for adding feature:

  1. Log out from the webclient
  2. One is still logged into the website.

Error output / Expected result of feature

The original reason for the auto-login is to avoid the case of having to log in twice (once for website and once for webclient). While one could argue that there is a potential advantage to be able to just auto-login to the webclient if still logged into the website, now logging out is a two-step process instead, where one has to go to the website in order to actually be able to login anew to the webclient. In short, logging out of the webclient should also log one out of the website.

Extra information, such as Evennia revision/repo/branch, operating system and ideas for how to solve / implement:

This requires going through and refactor the auto-login mechanism. There are several issues, such as #1061 and #1037.

@Griatch

This comment has been minimized.

Show comment
Hide comment
@Griatch

Griatch Sep 16, 2016

Member

Whereas the other issues have been closed, actually implementing this is more complex than expected. Notably because the webclient must somehow track so that it does not log out of the website if there are remaining (webclient-)Sessions connected; which is not immediately obvious how to determine.

Member

Griatch commented Sep 16, 2016

Whereas the other issues have been closed, actually implementing this is more complex than expected. Notably because the webclient must somehow track so that it does not log out of the website if there are remaining (webclient-)Sessions connected; which is not immediately obvious how to determine.

@Kelketek

This comment has been minimized.

Show comment
Hide comment
@Kelketek

Kelketek Sep 16, 2016

Contributor

@Griatch Can the webclient send an OOB command that queries all active sessions?

Contributor

Kelketek commented Sep 16, 2016

@Griatch Can the webclient send an OOB command that queries all active sessions?

@whitenoiseoss

This comment has been minimized.

Show comment
Hide comment
@whitenoiseoss

whitenoiseoss Sep 16, 2016

Something like reference counting would have to be implemented here. A way to query either by an API call, OOB command, whatever, and increment/decrement a "session count" and on log out if that count - 1 == 0, log out fully and destroy the website session.

whitenoiseoss commented Sep 16, 2016

Something like reference counting would have to be implemented here. A way to query either by an API call, OOB command, whatever, and increment/decrement a "session count" and on log out if that count - 1 == 0, log out fully and destroy the website session.

@Griatch

This comment has been minimized.

Show comment
Hide comment
@Griatch

Griatch Sep 19, 2016

Member

@Kelketek

It could, but it's not really up to the webclient itself to handle this I don't think, but the webclient's backend.

@whitenoiseoss

I did try querying the session count connected to a given player as my first attempt but ran into edge cases with the implementation. Will likely revisit to see if I can figure out a stable way to do it.

Member

Griatch commented Sep 19, 2016

@Kelketek

It could, but it's not really up to the webclient itself to handle this I don't think, but the webclient's backend.

@whitenoiseoss

I did try querying the session count connected to a given player as my first attempt but ran into edge cases with the implementation. Will likely revisit to see if I can figure out a stable way to do it.

@Griatch Griatch added this to TODO in Evennia 0.7 Feb 10, 2017

@Griatch

This comment has been minimized.

Show comment
Hide comment
@Griatch

Griatch Feb 10, 2017

Member

This was moved to the devel branch leading up to Evennia 0.7.

Member

Griatch commented Feb 10, 2017

This was moved to the devel branch leading up to Evennia 0.7.

@Griatch Griatch moved this from TODO to In progress on devel branch in Evennia 0.7 Aug 19, 2017

@Griatch Griatch moved this from In progress on devel branch to TODO in Evennia 0.7 Aug 19, 2017

@Griatch Griatch moved this from TODO to In progress on devel branch in Evennia 0.7 Aug 20, 2017

@Griatch Griatch moved this from In progress on devel branch to Done on devel branch in Evennia 0.7 Aug 20, 2017

@Griatch Griatch added the implemented label Aug 20, 2017

@Griatch

This comment has been minimized.

Show comment
Hide comment
@Griatch

Griatch Aug 20, 2017

Member

Implemented in devel.

Member

Griatch commented Aug 20, 2017

Implemented in devel.

@Griatch Griatch closed this in cdac967 Sep 20, 2017

@Griatch Griatch moved this from Todo to Finished in API expansion milestone Sep 20, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment