-
Notifications
You must be signed in to change notification settings - Fork 726
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
Check port availability #4333
Check port availability #4333
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #4333 +/- ##
===========================================
- Coverage 52.92% 52.91% -0.01%
===========================================
Files 718 718
Lines 22813 22810 -3
Branches 3096 3096
===========================================
- Hits 12073 12070 -3
Misses 10017 10017
Partials 723 723
Continue to review full report at Codecov.
|
@lyw07 I tested this PR in Ubuntu, and it did display the But on Windows it's still saying at the Command prompt that the kolibri running on |
a3ea584
to
cc03798
Compare
@mrpau-richard thank you for testing! I just pushed the fix for Windows and tested the Windows installer. It should be working now :) |
Great work @lyw07 , I tested it at the Windows. The port error logs are now working in the Command prompt. |
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.
I Tested this @lyw07.
@mrpau-richard thank you so much for testing! |
kolibri/utils/sanity_checks.py
Outdated
s.bind((host, port)) | ||
s.close() | ||
except socket.error: | ||
portend.free(host, port, timeout=2) |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
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.
Great + simplifying changes. portend
is already a dependency of cherrypy
, so no problem depending on it... just keep in mind that we'll follow the inferred cherrypy
version requirements for this one.
made the timeout into a constant as requested |
Summary
This PR is to fix the issue that the function for port availability check does not really work. Previously, because of the wrong host, the unavailable port error is not caught by the function
check_port_availability
but by cherrypy.Reviewer guidance
References
#4189
Contributor Checklist
Reviewer Checklist
yarn
andpip
)