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

Remove idle status #1

Merged
merged 3 commits into from
Feb 19, 2024
Merged

Remove idle status #1

merged 3 commits into from
Feb 19, 2024

Conversation

matthme
Copy link
Contributor

@matthme matthme commented Feb 19, 2024

There was an error in the logic that made peers never become "offline" since the logic to switch the state (lastSeenToStatus) was only being called if a Pong was received but if a peer is offline, a Pong would never be received.

While trying to fix it I noticed that in my opinion the "idle" status does not add a lot of value in that context (someone is either reachable within a certain time span or not reachable). The "idle" status how I'm used to from other applications would more be determined by whether that peer is active in the given application (e.g. whether they have the application focused or move their mouse around).

Since it also makes the solution to the issue simpler this PR therefore removes the "idle" status.

Copy link
Contributor

@guillemcordoba guillemcordoba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@matthme matthme merged commit 901af1d into main Feb 19, 2024
1 check failed
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

Successfully merging this pull request may close these issues.

2 participants