From 57307109e6f3801076325adfec2af5452fbe72fc Mon Sep 17 00:00:00 2001 From: Junzi Sun Date: Sat, 2 May 2020 19:32:54 +0200 Subject: [PATCH] remove python 2 imports --- pyModeS/__init__.py | 2 -- pyModeS/decoder/__init__.py | 3 --- pyModeS/decoder/adsb.py | 2 -- pyModeS/decoder/bds/__init__.py | 1 - pyModeS/decoder/bds/bds05.py | 3 --- pyModeS/decoder/bds/bds06.py | 2 -- pyModeS/decoder/bds/bds08.py | 2 -- pyModeS/decoder/bds/bds09.py | 3 --- pyModeS/decoder/bds/bds10.py | 2 -- pyModeS/decoder/bds/bds17.py | 3 --- pyModeS/decoder/bds/bds20.py | 2 -- pyModeS/decoder/bds/bds30.py | 2 -- pyModeS/decoder/bds/bds40.py | 2 -- pyModeS/decoder/bds/bds44.py | 2 -- pyModeS/decoder/bds/bds45.py | 2 -- pyModeS/decoder/bds/bds50.py | 2 -- pyModeS/decoder/bds/bds53.py | 2 -- pyModeS/decoder/bds/bds60.py | 2 -- pyModeS/decoder/commb.py | 2 -- pyModeS/decoder/common.py | 1 - pyModeS/decoder/ehs.py | 1 - pyModeS/decoder/els.py | 2 -- pyModeS/extra/__init__.py | 1 - pyModeS/extra/tcpclient.py | 1 - pyModeS/streamer/decode.py | 1 - pyModeS/streamer/modeslive | 1 - pyModeS/streamer/screen.py | 1 - setup.py | 4 ++-- tests/sample_run_commb.py | 1 - 29 files changed, 2 insertions(+), 53 deletions(-) diff --git a/pyModeS/__init__.py b/pyModeS/__init__.py index a2014df..4dacfcd 100644 --- a/pyModeS/__init__.py +++ b/pyModeS/__init__.py @@ -1,5 +1,3 @@ -from __future__ import absolute_import, print_function, division - import os import warnings diff --git a/pyModeS/decoder/__init__.py b/pyModeS/decoder/__init__.py index c56a9b1..2987ed1 100644 --- a/pyModeS/decoder/__init__.py +++ b/pyModeS/decoder/__init__.py @@ -1,6 +1,3 @@ -from __future__ import absolute_import, print_function, division - - def tell(msg): from pyModeS import common, adsb, commb, bds diff --git a/pyModeS/decoder/adsb.py b/pyModeS/decoder/adsb.py index 41a92ca..501fa4b 100644 --- a/pyModeS/decoder/adsb.py +++ b/pyModeS/decoder/adsb.py @@ -13,8 +13,6 @@ The ADS-B wrapper also imports functions from the following modules: """ -from __future__ import absolute_import, print_function, division - import pyModeS as pms from pyModeS import common diff --git a/pyModeS/decoder/bds/__init__.py b/pyModeS/decoder/bds/__init__.py index baea5b5..14b9959 100644 --- a/pyModeS/decoder/bds/__init__.py +++ b/pyModeS/decoder/bds/__init__.py @@ -18,7 +18,6 @@ Common functions for Mode-S decoding """ -from __future__ import absolute_import, print_function, division import numpy as np from pyModeS.extra import aero diff --git a/pyModeS/decoder/bds/bds05.py b/pyModeS/decoder/bds/bds05.py index ed9575f..0b271a7 100644 --- a/pyModeS/decoder/bds/bds05.py +++ b/pyModeS/decoder/bds/bds05.py @@ -4,9 +4,6 @@ # Airborn position # ------------------------------------------ - -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds06.py b/pyModeS/decoder/bds/bds06.py index 17c3fa1..95a96cf 100644 --- a/pyModeS/decoder/bds/bds06.py +++ b/pyModeS/decoder/bds/bds06.py @@ -4,8 +4,6 @@ # Surface position # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds08.py b/pyModeS/decoder/bds/bds08.py index 8bc03ae..3639c6f 100644 --- a/pyModeS/decoder/bds/bds08.py +++ b/pyModeS/decoder/bds/bds08.py @@ -4,8 +4,6 @@ # Aircraft identitification and category # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds09.py b/pyModeS/decoder/bds/bds09.py index aea62c8..8ed93a9 100644 --- a/pyModeS/decoder/bds/bds09.py +++ b/pyModeS/decoder/bds/bds09.py @@ -4,9 +4,6 @@ # Aircraft Airborn velocity # ------------------------------------------ -from __future__ import absolute_import, print_function, division -from pyModeS.decoder import common - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds10.py b/pyModeS/decoder/bds/bds10.py index 7d51c34..abaa974 100644 --- a/pyModeS/decoder/bds/bds10.py +++ b/pyModeS/decoder/bds/bds10.py @@ -3,8 +3,6 @@ # Data link capability report # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds17.py b/pyModeS/decoder/bds/bds17.py index 8dcc2fa..5a056c9 100644 --- a/pyModeS/decoder/bds/bds17.py +++ b/pyModeS/decoder/bds/bds17.py @@ -3,9 +3,6 @@ # Common usage GICB capability report # ------------------------------------------ - -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds20.py b/pyModeS/decoder/bds/bds20.py index 6c3dcfd..60eb94e 100644 --- a/pyModeS/decoder/bds/bds20.py +++ b/pyModeS/decoder/bds/bds20.py @@ -3,8 +3,6 @@ # Aircraft identification # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds30.py b/pyModeS/decoder/bds/bds30.py index 53c1ee9..a71eaeb 100644 --- a/pyModeS/decoder/bds/bds30.py +++ b/pyModeS/decoder/bds/bds30.py @@ -3,8 +3,6 @@ # ACAS active resolution advisory # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds40.py b/pyModeS/decoder/bds/bds40.py index 008505b..aca5613 100644 --- a/pyModeS/decoder/bds/bds40.py +++ b/pyModeS/decoder/bds/bds40.py @@ -3,9 +3,7 @@ # Selected vertical intention # ------------------------------------------ -from __future__ import absolute_import, print_function, division import warnings - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds44.py b/pyModeS/decoder/bds/bds44.py index 1ee5492..7e04de4 100644 --- a/pyModeS/decoder/bds/bds44.py +++ b/pyModeS/decoder/bds/bds44.py @@ -3,8 +3,6 @@ # Meteorological routine air report # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds45.py b/pyModeS/decoder/bds/bds45.py index 2c581ae..f740457 100644 --- a/pyModeS/decoder/bds/bds45.py +++ b/pyModeS/decoder/bds/bds45.py @@ -3,8 +3,6 @@ # Meteorological hazard report # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds50.py b/pyModeS/decoder/bds/bds50.py index 2d16f63..2a16999 100644 --- a/pyModeS/decoder/bds/bds50.py +++ b/pyModeS/decoder/bds/bds50.py @@ -3,8 +3,6 @@ # Track and turn report # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds53.py b/pyModeS/decoder/bds/bds53.py index 8b8a8df..34e98ca 100644 --- a/pyModeS/decoder/bds/bds53.py +++ b/pyModeS/decoder/bds/bds53.py @@ -3,8 +3,6 @@ # Air-referenced state vector # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/bds/bds60.py b/pyModeS/decoder/bds/bds60.py index d9de28f..e2074fa 100644 --- a/pyModeS/decoder/bds/bds60.py +++ b/pyModeS/decoder/bds/bds60.py @@ -3,8 +3,6 @@ # Heading and speed report # ------------------------------------------ -from __future__ import absolute_import, print_function, division - from pyModeS import common diff --git a/pyModeS/decoder/commb.py b/pyModeS/decoder/commb.py index e444038..c4409f6 100644 --- a/pyModeS/decoder/commb.py +++ b/pyModeS/decoder/commb.py @@ -19,8 +19,6 @@ The Comm-B wrapper imports all functions from the following modules: """ -from __future__ import absolute_import, print_function, division - # ELS - elementary surveillance from pyModeS.decoder.bds.bds10 import * from pyModeS.decoder.bds.bds17 import * diff --git a/pyModeS/decoder/common.py b/pyModeS/decoder/common.py index c1339a5..47ecb94 100644 --- a/pyModeS/decoder/common.py +++ b/pyModeS/decoder/common.py @@ -1,4 +1,3 @@ -from __future__ import absolute_import, print_function, division import numpy as np from textwrap import wrap diff --git a/pyModeS/decoder/ehs.py b/pyModeS/decoder/ehs.py index 8abf6ea..bb91a29 100644 --- a/pyModeS/decoder/ehs.py +++ b/pyModeS/decoder/ehs.py @@ -9,7 +9,6 @@ The EHS wrapper imports all functions from the following modules: """ -from __future__ import absolute_import, print_function, division import warnings from pyModeS.decoder.bds.bds40 import * diff --git a/pyModeS/decoder/els.py b/pyModeS/decoder/els.py index a028c9c..9c26b93 100644 --- a/pyModeS/decoder/els.py +++ b/pyModeS/decoder/els.py @@ -10,8 +10,6 @@ The ELS wrapper imports all functions from the following modules: """ -from __future__ import absolute_import, print_function, division - from pyModeS.decoder.bds.bds10 import * from pyModeS.decoder.bds.bds17 import * from pyModeS.decoder.bds.bds20 import * diff --git a/pyModeS/extra/__init__.py b/pyModeS/extra/__init__.py index f298a61..e69de29 100644 --- a/pyModeS/extra/__init__.py +++ b/pyModeS/extra/__init__.py @@ -1 +0,0 @@ -from __future__ import absolute_import, print_function, division diff --git a/pyModeS/extra/tcpclient.py b/pyModeS/extra/tcpclient.py index 4216e3e..0f18c54 100644 --- a/pyModeS/extra/tcpclient.py +++ b/pyModeS/extra/tcpclient.py @@ -1,6 +1,5 @@ """Stream beast raw data from a TCP server, convert to mode-s messages.""" -from __future__ import print_function, division import os import sys import time diff --git a/pyModeS/streamer/decode.py b/pyModeS/streamer/decode.py index cee02e0..5297262 100644 --- a/pyModeS/streamer/decode.py +++ b/pyModeS/streamer/decode.py @@ -1,4 +1,3 @@ -from __future__ import absolute_import, print_function, division import os import time import datetime diff --git a/pyModeS/streamer/modeslive b/pyModeS/streamer/modeslive index 6e803ee..47e7b58 100755 --- a/pyModeS/streamer/modeslive +++ b/pyModeS/streamer/modeslive @@ -1,6 +1,5 @@ #!/usr/bin/env python -from __future__ import print_function, division import os import sys import time diff --git a/pyModeS/streamer/screen.py b/pyModeS/streamer/screen.py index 5d83d41..ada1bf5 100644 --- a/pyModeS/streamer/screen.py +++ b/pyModeS/streamer/screen.py @@ -1,4 +1,3 @@ -from __future__ import print_function, division import curses import numpy as np import time diff --git a/setup.py b/setup.py index 9f62029..20aba5d 100644 --- a/setup.py +++ b/setup.py @@ -61,7 +61,7 @@ setup( "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", # Specify the Python versions you support here. In particular, ensure # that you indicate whether you support Python 2, Python 3 or both. - "Programming Language :: Python :: 2", + # "Programming Language :: Python :: 2", "Programming Language :: Python :: 3", ], ext_modules=cythonize(extensions), @@ -77,7 +77,7 @@ setup( # your project is installed. For an analysis of "install_requires" vs pip's # requirements files see: # https://packaging.python.org/en/latest/requirements.html - install_requires=["numpy", "argparse", "pyzmq", "pyrtlsdr"], + install_requires=["numpy", "pyzmq", "pyrtlsdr"], # List additional groups of dependencies here (e.g. development # dependencies). You can install these using the following syntax, # for example: diff --git a/tests/sample_run_commb.py b/tests/sample_run_commb.py index 9049cad..369f4e7 100644 --- a/tests/sample_run_commb.py +++ b/tests/sample_run_commb.py @@ -1,4 +1,3 @@ -from __future__ import print_function from pyModeS import commb, common, bds # === Decode sample data file ===