Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
7.4.0
-
None
Description
Python scripts rely on the operating system's default version of Python, but syntactically they require Python2. One example is /opt/HPCCSystems/sbin/cluster_script.py:
#!/usr/bin/env python import sys import os import os.path import getopt import Queue import time import datetime import logging import ConfigParser import signal
The module names Queue and ConfigParser are specific to Python2. The Python3 versions are 'queue' and 'configparser'. The shebang line indicates that we'll accept whatever version of Python the OS is referencing. The upshot is that if a user has set Python3 as the default then this script will fail.
This could be solved by either explicitly requiring Python2 in the shebang, or simply via documentation.