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

FastLogin integration plugin didn't report the correct client status in Plan #3485

Closed
Athar42 opened this issue Feb 23, 2024 · 9 comments
Closed
Labels
Bug Issues that contain unintended behavior DataExtensions Tickets related to DataExtensions status: Possibly Fixed Issues that are vague or hard to debug and might be solved

Comments

@Athar42
Copy link

Athar42 commented Feb 23, 2024

Describe the issue

The FastLogin integration plugin didn't report the correct client status in Plan.
All the clients are reported "Unknown".

Exceptions & Other Logs

Plan output on one of my test servers :
image

Plugin versions

Plan : 5.6 DEV 2731 (for both Velocity and PaperMC servers)
FastLogin : 1.12-SNAPSHOT-a65a5f3 (build 1298)
Authme : 5.6.0 2614
AuthmeVelocity : 4.1.1

Quick setup summary is as follow :
Proxy : Velocity
--> Connect to a lobby server (PaperMC)
----> Then connect to any game server from an In Game menu (loaded with FastLogin in "Proxy mode").
Not all server have PlaceholderAPI installed (but lobby has and it report the correct state, as noted below).

Additional information

Using the following command : /papi parse NICKNAME %fastlogin_status%
get the correct output (here : Premium)

My 2cents : It seems that the FastLogin integration request the status right away at the player connection.
As stated on the GitHub page, this issue could be due to the fact that the request of account status is delayed in a proxied environment :
image

@Athar42 Athar42 added the Bug Issues that contain unintended behavior label Feb 23, 2024
@AuroraLS3
Copy link
Collaborator

Thanks for the insight in how it might need to wait after login, I didn't know that ws the case so it should make it easier to fix it

@AuroraLS3 AuroraLS3 added the DataExtensions Tickets related to DataExtensions label Feb 23, 2024
@github-project-automation github-project-automation bot moved this to INBOX in Backlog Feb 23, 2024
@Athar42
Copy link
Author

Athar42 commented Feb 23, 2024

It's a simple guess, unsure if that's the cause of the behavior I witness here, but that's the best I came accross :D

If any tests needed (testing a new build, or anything to track this bug), feel free to ask me :)

@github-project-automation github-project-automation bot moved this from INBOX to Done in Backlog Mar 9, 2024
@AuroraLS3 AuroraLS3 added the status: Possibly Fixed Issues that are vague or hard to debug and might be solved label Mar 9, 2024
@AuroraLS3
Copy link
Collaborator

Please test this build https://github.com/plan-player-analytics/Plan/actions/runs/8213295818

It adds a 1 second wait before asking for the premium status.

@Athar42
Copy link
Author

Athar42 commented Mar 9, 2024

Little update, seems to look better, just a little one still fail so far.

So, most of my servers get correctly from :
image

to

image

But I still have a couple that didn't update correctly on the first login attempt like the lobby server.
Going back and forth from one server to another get the correct status.

So, seems fixed, but a greater delay might be needed :) (like 2, 3 or 5secs).

From the server page (other players didn't reconnect yet), so at least now, it can get the correct value, but I think the delay isn't enough right now :)
image

Edit: I think there is a typo on the comment :P "the API doesn't provide a Future." (not "Feature" ? )

@AuroraLS3
Copy link
Collaborator

AuroraLS3 commented Mar 9, 2024

A Future is a concept in Java where another thread than calling thread is performing a task - in this case FastAPI is getting the premium status.

If the FastAPI api returned a future I would be able to "wait until this is done" rather than add an arbitrary amount of seconds to wait

@AuroraLS3
Copy link
Collaborator

I'll reopen this in case it's FastAPI clearing the premium status on player leave and Plan recording that afterwards

@AuroraLS3 AuroraLS3 reopened this Mar 9, 2024
@github-project-automation github-project-automation bot moved this from Done to INBOX in Backlog Mar 9, 2024
@Athar42
Copy link
Author

Athar42 commented Mar 9, 2024

A Future is a concept in Java where another thread than calling thread is performing a task - in this case FastAPI is getting the premium status.

If the FastAPI api returned a future I would be able to "wait until this is done" rather than add an arbitrary amount of seconds to wait

Thanks for this info, I didn't knew it :)

I'll keep an eye here for any needed tests :)

@Athar42
Copy link
Author

Athar42 commented Mar 9, 2024

From the tests I made so far, it might be cleared on reconnection.

I think of that because when I join a server where I was previously set as "Premium", I get back to "Unknown" randomly.
But when I got set to "Premium" then go to another server, I still keep the "Premium" statut in PLAN.

If more tests needed, feel free to ask :)

@github-project-automation github-project-automation bot moved this from INBOX to Done in Backlog Mar 10, 2024
@Athar42
Copy link
Author

Athar42 commented Mar 10, 2024

Just a little reply after the latest update : This new change seems to do the trick, I didn't revert, on my short testing, to "Unknown" status.

As usual, great job, thanks for that nice plugin !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Issues that contain unintended behavior DataExtensions Tickets related to DataExtensions status: Possibly Fixed Issues that are vague or hard to debug and might be solved
Projects
Status: Done
Development

No branches or pull requests

2 participants