Skip to content

"Port already in use" error when restarting client after connection loss #147

Description

@ricardoapaes

While using the client software on a Windows machine, I noticed instances where it would stop functioning. I realized that when the internet connection dropped (internet connectivity in Brazil can be unreliable), the software wouldn't detect the outage and would stop working (which is expected). However, when the connection was restored, the software often failed to resume, especially after prolonged periods (more than 10 minutes).
As a workaround, I created a tool that polled for connectivity every minute. If the connection dropped, it would stop and restart the client. Unfortunately, I encountered a recurring issue: the error "port already in use" occurred frequently. After examining the code, I couldn't identify any obvious improvements, as it seemed to already include checks for removing stale connections.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions