-
-
Notifications
You must be signed in to change notification settings - Fork 46.7k
Travis CI: Add pytest --doctest-modules file_transfer_protocol #1044
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
Conversation
b106097
to
bb458f6
Compare
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.
In file_transfer_protocol/ftp_client_server.py
the client part of the code never runs because there is no exit condition (which is fine) that I see in the server's loop. Also, there is no way to run both the client or the server, they both have to be run.
conn.close() | ||
|
||
|
||
# client side server |
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.
Shouldn't the client side server be split into a separate file?
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.
given the loop above, this should be in a separate file
s.send("Hello server!") | ||
|
||
with open('received_file', 'wb') as f: | ||
print('file opened') | ||
while True: |
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.
This loop never exits, thus the client side server below never runs.
@AlexDvorak I agree. This PR was just trying to get the pytests to run across the entire repo. Please create a separate pull request that deals with all of the issues that you have raised. I will gladly review that PR when it passes our Travis CI tests and then close this PR in favor of yours |
@AlexDvorak Your thoughts on progressing this in a separate PR? |
That sounds good, I should have the PR open by tomorrow.
|
Fixes #983 The two Python files in the file_transfer_protocol directory currently fail the Travis CI pytests. This pull request makes the changes necessary for Travis CI to run pytest on these files without hanging.