Support py3.4 #371

Merged
merged 2 commits into from Aug 25, 2014

Projects

None yet

3 participants

@lndbrg
Contributor
lndbrg commented Aug 14, 2014

No description provided.

lndbrg added some commits Aug 14, 2014
@lndbrg lndbrg Join the threads with a low timeout.
Instead of using private methods on the threading class, let the
thread join, but with a low timeout.
a429e17
@lndbrg lndbrg Support py3.4. 075f5c0
@coveralls

Coverage Status

Coverage remained the same when pulling 075f5c0 on lndbrg:fix-python-threading-for-3.4 into 991d56b on paramiko:master.

@bitprophet bitprophet commented on the diff Aug 18, 2014
@@ -149,10 +149,7 @@ def main():
# TODO: make that not a problem, jeez
for thread in threading.enumerate():
if thread is not threading.currentThread():
- if PY2:
- thread._Thread__stop()
- else:
- thread._stop()
+ thread.join(timeout=1)
@bitprophet
bitprophet Aug 18, 2014 Member

How is this related to adding 3.4 support?

@lndbrg
lndbrg Aug 18, 2014 Contributor

The _stop method changed in 3.4 breaking most if not all used of _stop. The motivation for breaking it was that it was already broken anyway and that you shouldn't rely on underscore methods anyway.

TL;DR: _stop does not stop a thread and does not work as before in 3.4

@bitprophet
bitprophet Aug 25, 2014 Member

Huh. Well, as long as the tests still complete OK on all interpreters I guess I don't care :) just funny that we were apparently using a broken function in the past?

@bitprophet bitprophet added Support and removed Bug labels Aug 25, 2014
@bitprophet bitprophet added this to the 1.15 milestone Aug 25, 2014
@bitprophet bitprophet merged commit 075f5c0 into paramiko:master Aug 25, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details
@bitprophet bitprophet added a commit that referenced this pull request Aug 25, 2014
@bitprophet bitprophet Changelog re #371 5d010cd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment