Skip to content

Conversation

@MrAdder
Copy link

@MrAdder MrAdder commented May 26, 2025

Refactored my Auto Connect and Retry feature following the guidance from #12

Possibility to Fix #7

I have not tested this, so I apologise if this does not work first try.

Compiled test version for those who can not compile is linked below; however, it does not include #18

https://ci.appveyor.com/project/MrAdder/vsmr/builds/52123465

For a build that contains #18 as well, use

https://ci.appveyor.com/project/MrAdder/vsmr/builds/52123426

MrAdder added 2 commits May 26, 2025 13:47
Refactored and changed the Auto Logon and Retry features

Currently untested
@MrAdder MrAdder closed this May 26, 2025
@MrAdder MrAdder reopened this May 26, 2025
@MrAdder
Copy link
Author

MrAdder commented May 26, 2025

@19wintersp your insight into this is welcome
as well as @BenWalker01

@MrAdder MrAdder mentioned this pull request May 26, 2025
@19wintersp
Copy link

How does this address #2?

@MrAdder
Copy link
Author

MrAdder commented May 26, 2025

Forgot to commit that part its comming soon™

Copy link

@19wintersp 19wintersp left a comment

Choose a reason for hiding this comment

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

Please consider when re-formatting entire files that it can cause merge conflicts and makes reviewing harder. In future, if you do choose to re-format a file, please do it in a separate commit, apply it to all files, and include the formatting rules used (via .clang-format or similar).

There are quite a few instances of implicit casts which should be avoided, but there are worse things already in the codebase. Please do check the compiler output though, as I'm fairly sure at least some of them will be causing warnings to be produced—any such warnings should be addressed before merge.

@19wintersp
Copy link

Forgot to commit that part its comming soon™

Please do so in a separate PR if so.

I still believe some more consideration of the best course of action wrt #7 is warranted; I'll put some thoughts in the issue thread and would welcome others' input.

Unset the isConnecting variable when actually connecting ready for reconnecting attempts
@MrAdder MrAdder mentioned this pull request May 26, 2025
Copy link

@19wintersp 19wintersp left a comment

Choose a reason for hiding this comment

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

I implore you to please test your changes before submitting PRs, or at least mark it as a draft if you do not expect reviews yet.

@19wintersp
Copy link

Copying comments from #12:

I'm also not totally convinced of the utility of continued attempts at connection when doing so has failed already, since this is particularly liable to unnecessarily pestering the server with requests it has already deemed invalid (in the likely scenarios of invalid authentication or an existing conflicting connection), or shouting into the void (if it's a network problem).

As before, I think classifying the cause of failure to connect should be a prerequisite for any attempt at reconnection. What exactly is the intended scenario for which automatic retry on connection failure is to be used?

MrAdder added 2 commits May 26, 2025 17:52
- ReAdded Checks for if the client is a controller or observer
- Added notices Max retries and missing logon code
- fixed the login loop from the autoconnection
@MrAdder
Copy link
Author

MrAdder commented May 26, 2025

I have no issues with reviews at this stage, as ultimately it won't get merged until everyone is happy.

  • Tested my side. Empty logonCode
  • Max Retries
  • login loop

Still seeing if I can get any errors from Hoppies for an inactive Hoppies code

@BenWalker01
Copy link
Collaborator

@MrAdder Been busy, sorry. Can't remember where this was up to. Has the auto connect been removed?

@MrAdder
Copy link
Author

MrAdder commented Jul 15, 2025

Will try to remove that in the morning before work; however, sleep is needed

@MrAdder
Copy link
Author

MrAdder commented Jul 20, 2025

@BenWalker01 Done, sorry work kicked up due to weather

@19wintersp
Copy link

My previous comment regarding reconnection still stands; I think at minimum an exponential backoff should be implemented for this to be considered at all

@BenWalker01
Copy link
Collaborator

Please consider when re-formatting entire files that it can cause merge conflicts and makes reviewing harder. In future, if you do choose to re-format a file, please do it in a separate commit, apply it to all files, and include the formatting rules used (via .clang-format or similar).

There are quite a few instances of implicit casts which should be avoided, but there are worse things already in the codebase. Please do check the compiler output though, as I'm fairly sure at least some of them will be causing warnings to be produced—any such warnings should be addressed before merge.

Coming back to this, as a few people are working on the file, please keep your changes specific to the part you are working on. Please revert any formatting changes, not relevant to the content you are adding.

For @19wintersp you are correct re the compiler output. I'll fix it eventually (probably).

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.

PDC reminder

3 participants