diff --git a/tests/block_weight/block_weight.py b/tests/block_weight/block_weight.py index a17e05241..637fb804e 100755 --- a/tests/block_weight/block_weight.py +++ b/tests/block_weight/block_weight.py @@ -1,9 +1,8 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # Simulate a maximal block attack on the Monero network # This uses the scheme proposed by ArticMine # Written by Sarang Nother # Copyright (c) 2019-2024, The Monero Project -from __future__ import print_function import sys import math diff --git a/tests/block_weight/compare.py b/tests/block_weight/compare.py index e046e1640..daf3bca12 100755 --- a/tests/block_weight/compare.py +++ b/tests/block_weight/compare.py @@ -1,6 +1,5 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 -from __future__ import print_function import sys import subprocess diff --git a/tests/difficulty/gen_wide_data.py b/tests/difficulty/gen_wide_data.py index 64af4e208..9df11ac62 100755 --- a/tests/difficulty/gen_wide_data.py +++ b/tests/difficulty/gen_wide_data.py @@ -1,6 +1,5 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 -from __future__ import print_function import random DIFFICULTY_TARGET = 120 diff --git a/tests/difficulty/generate-data b/tests/difficulty/generate-data index 24926796a..0f0a549f7 100755 --- a/tests/difficulty/generate-data +++ b/tests/difficulty/generate-data @@ -1,4 +1,4 @@ -#!/usr/bin/python3 +#!/usr/bin/env python3 # Copyright (c) 2014-2024, The Monero Project # diff --git a/tests/difficulty/wide_difficulty.py b/tests/difficulty/wide_difficulty.py index 41a2a632d..7fb030bc4 100755 --- a/tests/difficulty/wide_difficulty.py +++ b/tests/difficulty/wide_difficulty.py @@ -1,6 +1,5 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 -from __future__ import print_function import sys import subprocess diff --git a/tests/functional_tests/address_book.py b/tests/functional_tests/address_book.py index 84365fe8c..c6090e253 100755 --- a/tests/functional_tests/address_book.py +++ b/tests/functional_tests/address_book.py @@ -32,7 +32,6 @@ """Test wallet address book RPC """ -from __future__ import print_function from framework.wallet import Wallet class AddressBookTest(): diff --git a/tests/functional_tests/bans.py b/tests/functional_tests/bans.py index fa0a19664..1f9a5bb9c 100755 --- a/tests/functional_tests/bans.py +++ b/tests/functional_tests/bans.py @@ -28,7 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import time """Test peer baning RPC calls diff --git a/tests/functional_tests/blockchain.py b/tests/functional_tests/blockchain.py index db0bd2eef..c1b610596 100755 --- a/tests/functional_tests/blockchain.py +++ b/tests/functional_tests/blockchain.py @@ -29,7 +29,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import time """Test daemon blockchain RPC calls diff --git a/tests/functional_tests/check_missing_rpc_methods.py b/tests/functional_tests/check_missing_rpc_methods.py index 0eedd6d0f..54f2e5de4 100644 --- a/tests/functional_tests/check_missing_rpc_methods.py +++ b/tests/functional_tests/check_missing_rpc_methods.py @@ -1,6 +1,5 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 -from __future__ import print_function import sys import re diff --git a/tests/functional_tests/cold_signing.py b/tests/functional_tests/cold_signing.py index 38e1baa26..bb9b536c5 100755 --- a/tests/functional_tests/cold_signing.py +++ b/tests/functional_tests/cold_signing.py @@ -31,7 +31,6 @@ """Test cold tx signing """ -from __future__ import print_function from framework.daemon import Daemon from framework.wallet import Wallet import random diff --git a/tests/functional_tests/daemon_info.py b/tests/functional_tests/daemon_info.py index 9d645330d..e7a67871f 100755 --- a/tests/functional_tests/daemon_info.py +++ b/tests/functional_tests/daemon_info.py @@ -37,7 +37,6 @@ Test the following RPCs: """ -from __future__ import print_function import os from framework.daemon import Daemon diff --git a/tests/functional_tests/functional_tests_rpc.py b/tests/functional_tests/functional_tests_rpc.py index e483352a4..ca55ed301 100755 --- a/tests/functional_tests/functional_tests_rpc.py +++ b/tests/functional_tests/functional_tests_rpc.py @@ -1,6 +1,5 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 -from __future__ import print_function import sys import time import subprocess diff --git a/tests/functional_tests/get_output_distribution.py b/tests/functional_tests/get_output_distribution.py index 54cb63035..1d127da97 100755 --- a/tests/functional_tests/get_output_distribution.py +++ b/tests/functional_tests/get_output_distribution.py @@ -31,7 +31,6 @@ """Test get_output_distribution RPC """ -from __future__ import print_function from framework.daemon import Daemon from framework.wallet import Wallet diff --git a/tests/functional_tests/integrated_address.py b/tests/functional_tests/integrated_address.py index 912bee26a..1009fc1fc 100755 --- a/tests/functional_tests/integrated_address.py +++ b/tests/functional_tests/integrated_address.py @@ -36,7 +36,6 @@ Test the following RPCs: """ -from __future__ import print_function from framework.wallet import Wallet class IntegratedAddressTest(): diff --git a/tests/functional_tests/k_anonymity.py b/tests/functional_tests/k_anonymity.py index 1182d29c8..0225faab6 100755 --- a/tests/functional_tests/k_anonymity.py +++ b/tests/functional_tests/k_anonymity.py @@ -28,7 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import math import random diff --git a/tests/functional_tests/mining.py b/tests/functional_tests/mining.py index aa7e291b5..08b470364 100755 --- a/tests/functional_tests/mining.py +++ b/tests/functional_tests/mining.py @@ -29,7 +29,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import time import os import math diff --git a/tests/functional_tests/multisig.py b/tests/functional_tests/multisig.py index c29cd1322..7c75493eb 100755 --- a/tests/functional_tests/multisig.py +++ b/tests/functional_tests/multisig.py @@ -28,7 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import random """Test multisig transfers diff --git a/tests/functional_tests/p2p.py b/tests/functional_tests/p2p.py index 8d92318ce..b878d0f14 100755 --- a/tests/functional_tests/p2p.py +++ b/tests/functional_tests/p2p.py @@ -29,7 +29,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import time """Test daemon P2P diff --git a/tests/functional_tests/proofs.py b/tests/functional_tests/proofs.py index 83869a063..2268df14b 100755 --- a/tests/functional_tests/proofs.py +++ b/tests/functional_tests/proofs.py @@ -28,8 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function - """Test misc proofs (tx key, send, receive, reserve) """ diff --git a/tests/functional_tests/rpc_payment.py b/tests/functional_tests/rpc_payment.py index 5b65b5af4..b2a9ca47d 100755 --- a/tests/functional_tests/rpc_payment.py +++ b/tests/functional_tests/rpc_payment.py @@ -28,7 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import subprocess import os import time diff --git a/tests/functional_tests/sign_message.py b/tests/functional_tests/sign_message.py index 9d6692cf8..9ee5913dc 100755 --- a/tests/functional_tests/sign_message.py +++ b/tests/functional_tests/sign_message.py @@ -28,8 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function - """Test message signing/verification RPC calls Test the following RPCs: diff --git a/tests/functional_tests/speed.py b/tests/functional_tests/speed.py index 9f3514a0d..d1e6aa169 100755 --- a/tests/functional_tests/speed.py +++ b/tests/functional_tests/speed.py @@ -41,7 +41,6 @@ Test the following RPCs: import time from time import sleep -from __future__ import print_function from framework.daemon import Daemon from framework.wallet import Wallet diff --git a/tests/functional_tests/transfer.py b/tests/functional_tests/transfer.py index 2987ded89..ef80dc739 100755 --- a/tests/functional_tests/transfer.py +++ b/tests/functional_tests/transfer.py @@ -28,7 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function import json import util_resources import pprint diff --git a/tests/functional_tests/txpool.py b/tests/functional_tests/txpool.py index 8e4d9c6eb..a7b321e8d 100755 --- a/tests/functional_tests/txpool.py +++ b/tests/functional_tests/txpool.py @@ -28,8 +28,6 @@ # STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF # THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -from __future__ import print_function - """Test txpool """ diff --git a/tests/functional_tests/uri.py b/tests/functional_tests/uri.py index 7d42c5ef8..fb981b3fd 100755 --- a/tests/functional_tests/uri.py +++ b/tests/functional_tests/uri.py @@ -32,7 +32,6 @@ """Test URI RPC """ -from __future__ import print_function try: from urllib import quote as urllib_quote except: diff --git a/tests/functional_tests/util_resources.py b/tests/functional_tests/util_resources.py index 9c879b27c..f5ef45166 100755 --- a/tests/functional_tests/util_resources.py +++ b/tests/functional_tests/util_resources.py @@ -34,7 +34,6 @@ by running numerical calculations """ -from __future__ import print_function import subprocess import psutil import os diff --git a/tests/functional_tests/validate_address.py b/tests/functional_tests/validate_address.py index c237ba0c2..dae4a6e68 100755 --- a/tests/functional_tests/validate_address.py +++ b/tests/functional_tests/validate_address.py @@ -31,7 +31,6 @@ """Test address validation RPC calls """ -from __future__ import print_function from framework.wallet import Wallet class AddressValidationTest(): diff --git a/tests/functional_tests/wallet.py b/tests/functional_tests/wallet.py index b55a07a70..68ff4ebf8 100755 --- a/tests/functional_tests/wallet.py +++ b/tests/functional_tests/wallet.py @@ -32,7 +32,6 @@ """Test basic wallet functionality """ -from __future__ import print_function import sys import util_resources