-
Notifications
You must be signed in to change notification settings - Fork 110
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
Make everserver port selection random #10010
Make everserver port selection random #10010
Conversation
CodSpeed Performance ReportMerging #10010 will not alter performanceComparing Summary
|
@@ -273,7 +274,8 @@ def get_shared_data( | |||
|
|||
|
|||
def _find_open_port(host, lower, upper) -> int: | |||
for port in range(lower, upper): | |||
for _ in range(5): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just 5 tries seems a low number.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It tries 5 times to randomly find a port not in use in the range 5000 to 5800. Should be low probability of not finding one
@@ -273,7 +274,8 @@ def get_shared_data( | |||
|
|||
|
|||
def _find_open_port(host, lower, upper) -> int: | |||
for port in range(lower, upper): | |||
for _ in range(5): | |||
port = random.randint(lower, upper) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe add a comment just to have an idea why this was needed so that once we update further everserver we might undo it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks ok but as you mentioned this will not completely solve the underlying issue.
I will up the retry to 10 and add a comment |
46d8668
to
8d9ceba
Compare
8d9ceba
to
a459d69
Compare
Issue
Resolves #9934
Approach
Short description of the approach
(Screenshot of new behavior in GUI if applicable)
git rebase -i main --exec 'just rapid-tests'
)When applicable