From 81199eaf0e7e78144617c277798bf0c944f7b2c7 Mon Sep 17 00:00:00 2001 From: rl1987 Date: Fri, 14 Sep 2018 19:47:02 +0300 Subject: [PATCH 1/3] Remove misleading first line in test_rebind.py test_rebind.py actually does not require Python 3. Bugfix on 5a11670fcaad0a58de48425ba80510effbe35628; bug not in any Tor release. --- src/test/test_rebind.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/test/test_rebind.py b/src/test/test_rebind.py index f02cb79b78..42a4658b49 100644 --- a/src/test/test_rebind.py +++ b/src/test/test_rebind.py @@ -1,5 +1,3 @@ -#!/usr/bin/python3 - from __future__ import print_function import sys From d40b0e73c278cd54c6c4765f35b4d031a5882562 Mon Sep 17 00:00:00 2001 From: rl1987 Date: Fri, 14 Sep 2018 20:13:23 +0300 Subject: [PATCH 2/3] Check Python version in test_rebind.py --- src/test/test_rebind.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/test/test_rebind.py b/src/test/test_rebind.py index 42a4658b49..7ba3a5796d 100644 --- a/src/test/test_rebind.py +++ b/src/test/test_rebind.py @@ -35,6 +35,12 @@ def pick_random_port(): return port +if sys.hexversion < 0x02070000: + sys.exit("ERROR: unsupported Python version (should be >= 2.7)") + +if sys.hexversion > 0x03000000 and sys.hexversion < 0x03010000: + sys.exit("ERROR: unsupported Python3 version (should be >= 3.1)") + control_port = pick_random_port() socks_port = pick_random_port() From 53d8aa13682caccbad3fff094c78cc4229e8fe13 Mon Sep 17 00:00:00 2001 From: rl1987 Date: Fri, 21 Sep 2018 10:57:10 +0300 Subject: [PATCH 3/3] Add changes file --- changes/bug27675 | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 changes/bug27675 diff --git a/changes/bug27675 b/changes/bug27675 new file mode 100644 index 0000000000..e4c3eb5a05 --- /dev/null +++ b/changes/bug27675 @@ -0,0 +1,3 @@ + o Minor bugfixes (testing): + - In test_rebind.py check if Python version is in supported + ranges. Fixes bug 27675; bugfix on 0.3.5.1-alpha.