[4/9] devtools/update_version_map: add python2 deprecation notice
Checks
Commit Message
Cc: Neil Horman <nhorman@tuxdriver.com>
Cc: Ray Kinsella <mdr@ashroe.eu>
Signed-off-by: Louise Kilheeney <louise.kilheeney@intel.com>
---
devtools/update_version_map_abi.py | 4 ++++
1 file changed, 4 insertions(+)
Comments
On Fri, Jul 10, 2020 at 11:10:50AM +0100, Louise Kilheeney wrote:
> Cc: Neil Horman <nhorman@tuxdriver.com>
> Cc: Ray Kinsella <mdr@ashroe.eu>
>
> Signed-off-by: Louise Kilheeney <louise.kilheeney@intel.com>
> ---
> devtools/update_version_map_abi.py | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/devtools/update_version_map_abi.py b/devtools/update_version_map_abi.py
> index e2104e61e..80a61641e 100755
> --- a/devtools/update_version_map_abi.py
> +++ b/devtools/update_version_map_abi.py
> @@ -160,6 +160,10 @@ def __generate_internal_abi(f_out, lines):
> print("};", file=f_out)
>
> def __main():
> + if sys.version_info.major < 3:
> + print("WARNING: Python 2 is deprecated for use in DPDK, and will not work in future releases.", file=sys.stderr)
> + print("Please use Python 3 instead", file=sys.stderr)
> +
> arg_parser = argparse.ArgumentParser(
> description='Merge versions in linker version script.')
>
> --
> 2.17.1
>
>
Acked-by: Neil Horman <nhorman@tuxdriver.com><
On 10/07/2020 11:10, Louise Kilheeney wrote:
> Cc: Neil Horman <nhorman@tuxdriver.com>
> Cc: Ray Kinsella <mdr@ashroe.eu>
>
> Signed-off-by: Louise Kilheeney <louise.kilheeney@intel.com>
> ---
> devtools/update_version_map_abi.py | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/devtools/update_version_map_abi.py b/devtools/update_version_map_abi.py
> index e2104e61e..80a61641e 100755
> --- a/devtools/update_version_map_abi.py
> +++ b/devtools/update_version_map_abi.py
> @@ -160,6 +160,10 @@ def __generate_internal_abi(f_out, lines):
> print("};", file=f_out)
>
> def __main():
> + if sys.version_info.major < 3:
> + print("WARNING: Python 2 is deprecated for use in DPDK, and will not work in future releases.", file=sys.stderr)
> + print("Please use Python 3 instead", file=sys.stderr)
> +
> arg_parser = argparse.ArgumentParser(
> description='Merge versions in linker version script.')
>
>
Is the simpler way to resolve this, for the script be explicit about its requirements.
Something like
#!/usr/bin/env python3
I also noted recently that rpm packaging requirements, seem to demands this from scripts now?
Thanks,
Ray K
@@ -160,6 +160,10 @@ def __generate_internal_abi(f_out, lines):
print("};", file=f_out)
def __main():
+ if sys.version_info.major < 3:
+ print("WARNING: Python 2 is deprecated for use in DPDK, and will not work in future releases.", file=sys.stderr)
+ print("Please use Python 3 instead", file=sys.stderr)
+
arg_parser = argparse.ArgumentParser(
description='Merge versions in linker version script.')